#!/bin/sh # v1.0 08-Nov-2000 JP Vossen (modifed for ntp, not xntp) # From: http://www.eecis.udel.edu/~mills/ntp/html/hints/solaris.xtra.S99ntpd if [ $1 = "start" ]; then if [ -x /usr/local/bin/ntpd ]; then echo "Starting NTP daemon, takes about 1 minute... " # dosynctodr may need to be left alone as of with Solaris 2.6 # The following line is unnecessary if you turn off # dosynctodr in /etc/system. /usr/local/bin/tickadj -s /usr/local/bin/ntpdate -v 172.22.1.254 172.22.1.253 sleep 5 /usr/local/bin/ntpd fi else if [ $1 = "stop" ]; then pid=`/usr/bin/ps -e | /usr/bin/grep ntpd | /usr/bin/sed -e 's/^ *//' -e 's/ .*//'` if [ "${pid}" != "" ]; then echo "Stopping Network Time Protocol daemon " /usr/bin/kill ${pid} fi fi fi