users@glassfish.java.net

Using asadmin create-service on Solaris as non-root

From: Alex Sherwin <alex.sherwin_at_acadiasoft.com>
Date: Wed, 21 Oct 2009 16:22:06 -0400

Is it possible to use create-service on Solaris as a non-root user?

I've tried adding the solaris.smf auths to my user such as "usermod -A
solaris.smf.* [my_user]" without luck, as well as following the
instructions in the "Restricting Service Administration in the Solaris
10 Operating System" guide 819-2887.pdf, which has you create a role for
the "Service Management" and assign the role to the user, which I have
done as well, to no avail.

I see this error when I try to run the command as non-root:

-bash-3.00$ asadmin create-service --passwordfile
/export/home/[my_user]/domains/[my_domain]/config/service.passwd
--serviceproperties net_privaddr /export/home/[my_user]/domains/[my_domain]
The user [[my_user]] does not have permission to create the service
manifest related files and directories at
[/var/svc/manifest/application/SUNWappserver/]. This structure is
required per SMF guidelines. Either become super-user to do this
operation or contact the System Administrator to explicitly get the
relevant permissions and try again.