The general steps required are: o Determine the proccess for starting and stopping your service. o Establish a name for the service, and the category this service falls into. o Determine whether your service runs multiple instances. o Identify any dependency relationships between this service and any other service. o If a script is required to start and stop the process, create the script and place it in a local directory such as /usr/local/svc/method o Create a service manifest file for your service. This file describes the service and any dependency relationships. Service manifests are pulled into the repository either by using svccfg command or at boot time. o Incorporate the scripts into SMF using the svccfg utility.
The following displays an example.
The following describes the entries in the file:
o Standard Header. o Comment Section. o The name of the service. the type(manifest) indicates a simple service rather than a milestone, the package providing the service, and the service name. o Service category, type, name and version. o Whether multiple instances of the service will run. o the service model to use. The entry shows that the service will be started by svc.startd. transient services are started once and not restarted. o How the service is started and stopped. o Define any dependencies for this service. The first entry states that the newservice requires the filesystem/local service. o The second entry makes sure that your service is associated with the multi-user milestone and that the multi-user milestone requires this service. o Creating the instance. o Creating information to describe the service.
The new service (newservice) now needs to be imported into SMF.
This is done by running the svccfg utility:
After the service has been imported into the SMF it should be visable using the svcs command.
It should also be possible to manipulate the service using svcadm.
Finally, you can observe that the multiuser milestone requires the newservice in order to complete its requirements.
Last edited by blowtorch; 11-16-2006 at 09:12 PM..
Reason: to fix incomplete xml tag for service. the closing '>' was not present
On one of our server inetd service has stuck in transition state , tried restarting it but it does not do any thing and there is no associated inetd process for the same , how can i start it .. w/o rebooting it
svcs inetd
STATE STIME FMRI
online* 16:44:55... (3 Replies)
hi,
any body have a idea how to create a service in sunsolaries(like windows).is it possible to create a service?.if any body having idea help me?
regards
suresh (3 Replies)
Hello Friends,
Does anyone know how to create a startup script for Jboss on IBM AIX 5.3?
Please help me, I'd be highly grateful to you...
Thanks & Regards,
Vinit (0 Replies)
Hai Friends
I have written a DayTime server program using C socket.. I need to start the service automatically. My service directory is /etc/rc.d/init.d... my service name is DayTime present in /home/codebase/datetime/ directory.. Please help me
:confused: :confused: :confused:
Thanks in... (2 Replies)