Local System Processes
This process_system_local_objects.cfg example specifies some local system processes. Pikt scripts use this, for example, to report process failure, and automatically restart failed processes if called for.
/////////////////////////////////////////////////////////////////////////////// // // process_system_local_objects.cfg // /////////////////////////////////////////////////////////////////////////////// // the format of this stanza is // // <process> : <interpreter> : .|<restart command> // // a . (dot) says to report the process failure, usually in cases where the // restart procedure is not straightforward #if nisserver ypserv : : /usr/lib/netsvc/yp/ypserv -d #endif #if nismaster ypxfrd : : /usr/lib/netsvc/yp/ypxfrd rpc.ypupdated : : /usr/lib/netsvc/yp/rpc.upupdated rpc.yppasswdd : : /usr/lib/netsvc/yp/rpc.yppasswdd #endif #if athens2 | athens4 dbms : iidbms : . recovery : iidbms : . dmfacp : : . #endif #if athens2 | athens4 | milan iigcn : : . iigcc : : . #endif #if moscow httpd : : /etc/rc3.d/S80httpd start // mysqld : : /etc/rc3.d/S33mysql start #endif #if warsaw // we'll let ak work out the details of how to restart ns-httpd : : . // nntp service innd : : . // to start, use: // /export/home/suitespot/start // to stop, use: // /export/home/suitespot/stop // other related procs: nnrpd : : . // rundsync : : . // srchs : : . newstime : : . uxwdog : : . ns-slapd : : /export/home/netscape/slapd/start-slapd rmserver : : /opt/real/rmserver /opt/real/rmserver.cfg & #endif #if vienna smbd : : /usr/local/samba/bin/smbd -D nmbd : : /usr/local/samba/bin/nmbd -D #endif #if moscow aliasmgr : perl : /etc/rc3.d/S81aliasmgr #endif #if moscow watcher : perl : /etc/rc3.d/S29popauth allow : sh : /etc/rc3.d/S29popauth #endif #if moscow maillistup : perl : /etc/rc3.d/S33maillist #endif #if rotterdam java : : /etc/rc3.d/S92vchat start ns-httpd : : /etc/rc3.d/S91ns-servers start #endif // check for various license daemons (what a mess!) ///////////////////////////////////////////////////////////////////////////////
On the piktmaster system, we would install the ProcessesSystem.obj file to each PIKT slave system with the command:
# piktc -iv +O ProcessesSystem +H all [or: ... -H down]
For more examples, see Samples.