Hi guys,
I want to add a new 'service' to Solaris 10. Does anyone have any documentation that tells how to do that?
I have gone through a bunch of stuff on the net that tells how to enable, disable services, find whats wrong with a service and so on. All conveniently skip mention of how to actually add a new service of your own.
I checked the files in /var/svc/manifest, and I know that they are the xmls that are used by the svcadm and its ilk, but does adding a new 'service' mean writing one of those xml files yourself?
-edit
Don't like the word service - feels too Windowsy
-/edit
- Create your shell start stop script and save it in /usr/local/svc/method/myservice
- chmod 755 /usr/local/svc/method/myservice
- Create your xml file and save it in /var/svc/manifest/site/myservice.xml
- Incorporate the script into the SMF using svccfg utility
note:
replace myservice with the name of the service you are adding.
I am going through the doco I have, I will have to type a couple of pages worth inbetween doing my other work so it will take me a while to type it up for you..
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.
Hi Folks,
I'm currently in a position where I am building the seed equipment for a Data Centre Migration, I'm familiar with some of the equipment - all of which I've listed below.
SAN Storage - EMC VNX5800
SAN Switches - Brocade DCX 8510-4
SAN Management - IBM SVC 2145-DH8 four node cluster... (2 Replies)
Hi,
Running ftp
online 2:53:02 svc:/network/ftp:default
If I disable ftp
disabled 2:54:00 svc:/network/ftp:default
I can still SEND ftp files out.
I cannot connect to this server via FTP, but why can I still connect to other ftp servers and send files?
Cheers. (5 Replies)
Dear All,
http:apache2 service on my node is continuously in maintenance mode.
I have tried to enable and disable the service but nothing works.
root@ops # svcs -a | grep apache2
maintenance 15:46:37 svc:/network/http:apache2
When I reboot the system, I get the following error:
... (1 Reply)
Hi all
I have a newly installed Oracle X2-4 server running Solaris 10 x86 with the latest patches.
I have one non-global zone configured running an Oracle DB instance.
After configuring IPMP failover between two NICs on the server and rebooting I am seeing the /var/adm/messages being flooded... (7 Replies)
After a memory upgrade all network interfaces are misconfigued. How do i resolve this issue. Below are some out puts.thanks.
ifconfig: plumb: SIOCLIFADDIF: eg000g0:2: no such interface
# ifconfig eg1000g0:2 plumb
ifconfig: plumb: SIOCLIFADDIF: eg1000g0:2: no such interface
# ifconfig... (2 Replies)
Hello Friends,
I need to change network filesystem status as online but it always seems in maintenance mode, I appreciate your any suggestion to change its state as online.
shell>svcadm enable svc:/system/filesystem/local
shell>svcs -l svc:/system/filesystem/local
fmri ... (4 Replies)
I'm having these weird errors.
svc.configd: Fatal error: Backend copy failed: fails to read from /etc/svc/repository.db at offset 106496: Bad file number
svc.configd: Fatal error: unable to create "boot" backup of "/etc/svc/repository.db"
Mar 10 13:04:23 svc.startd:... (5 Replies)
Hello Unix Admins:
Has any one in this distribution list implemented SVC (SAN Volume Contoller - A solution from IBM) in your environment? If you have, do you have any do's / don'ts? Anything which you like sharing would be really appreciated.
For example, my inputs:
I tried implementing... (1 Reply)
Dear all,
Recently I did an upgrade from Solaris 9 to Solaris 10 on a V440 System, after the initial reboot after the auto-reboot from the OS upgrade, the service: svc:/system/webconsole:console transitions into maintenance and cannot be manually brought online.
Below are a list of things I... (0 Replies)
hi, i have got a
SUN F15K DOMAIN TAKING HARDWARE CONFIGURATION DUMP. DUMP FILE: -D/VA message
i wnat to logon as sms-svc on to the controller to check what's happening
can you please guide me how do i login as sms-svc on the controller and check
thank you (1 Reply)