* Tony Nguyen <Truong.Q.Nguyen at Sun.COM> [2006-12-19 17:29]: > Dean Stanton wrote: > >LSARC asked me to create an SMF service to start my server > >on Solaris 10, though we use an init.d script on Solaris 8 & 9. > >My service depends on N1 Grid Engine having already started. > >N1GE's queue master is started by > > /etc/rc2.d/S95sgemaster -> /etc/init.d/sgemaster > >-- it has not been converted to use SMF. > > > >How do I depend on that script having been started, > >rather than merely that the multi-user milestone has been achieved? > > > >When sgemaster starts, it leaves its pid in > >/gridware/sge/default/spool/qmaster/qmaster.pid > >(but of course there could be an old PID there from a prior boot).
> I'm not sure how to establish dependency on a running rc script. > However, your service's start-up method can do a pgrep -x to figure out > whether sgemaster is running before starting the service. If there's only an rc*.d script, then there's no means within the framework to state a dependency. You could use Tony's method, although I would recommend making a trial connection to the N1GE server using whatever qstat(1) invocation would be like a ping. - Stephen -- Stephen Hahn, PhD Solaris Kernel Development, Sun Microsystems stephen.hahn at sun.com http://blogs.sun.com/sch/