start programs automatic at boot-time

Hi AllI need to start some software when solaris boots. Right now its ntpd. However I have no clue how to do this with Solaris 10. I assume there is a tool to do this, something likerc-update add ntpd default (the GenToo way)Thanks a lotLuCa
[283 byte] By [abcde-tje] at [2007-11-26 11:38:14]
# 1

You can either create a startup script and place it within the /etc/rc.<runlevel> directory beginning with a capital S and accepting the argument 'start'.

Or you can create a Solaris 10 service. You'd need to modify an existing manifest that would name the service, point to the right startup script (method) and establish the startup dependencies that describe when it should launch.

The first method is fast and quick, but not very fine grained. You can only launch in certain time periods. Creating a service involves a little more effort to get started, but gives monitoring/restart features along with explicit dependencies between services.

--

Darren

Darren_Dunham at 2007-7-7 11:37:43 > top of Java-index,General,Maintenance...
# 2

I just found a command that actually does what I need:

svcadm enable network/ntp

After a reboot I see the following $pgrep -l ntp

215 xntpd

And ntpq -p show a list of servers

Is this much different than your solutions ?

I tried this because I couldn't find a startup script for the ntpd!

Thnx

LuCa

abcdetje at 2007-7-7 11:37:43 > top of Java-index,General,Maintenance...
# 3
I'm sorry. I though you were interested in how to start generic applications at boot, not how to run NTP.Yes, xntpd should be automatically set to run at boot. You just need to put a correct /etc/inet/ntp.conf file in place for it to keep running.-- Darren
Darren_Dunham at 2007-7-7 11:37:44 > top of Java-index,General,Maintenance...
# 4
ok , so not all programs can be handled with svcadm!Do you know some good documentation about the stuff discussed above ?Thanks a lotLuCa
abcdetje at 2007-7-7 11:37:44 > top of Java-index,General,Maintenance...
# 5

Services are handled with svcadm. Most services are distributed with the OS, but you can create your own by making a service manifest for it and installing it.

There is an SMF FAQ that people are developing.

http://home.arcor.de/bnsmb/public/htdocs/My_Little_SMF_FAQ.html

--

Darren

Darren_Dunham at 2007-7-7 11:37:44 > top of Java-index,General,Maintenance...