Magellan Linux

Annotation of /trunk/rdate/rdate.rc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 124 - (hide annotations) (download)
Mon Mar 26 19:25:18 2007 UTC (17 years, 7 months ago) by niro
File size: 638 byte(s)
- nice colors

1 niro 123 #!/bin/bash
2 niro 124 # $Header: /root/magellan-cvs/src/rdate/rdate.rc,v 1.2 2007-03-26 19:25:18 niro Exp $
3 niro 123
4     #%rlevels: 3:s 4:s 5:s
5     #%start: 30
6     #%stop:
7    
8     #deps
9     #%needs:
10     #%before:
11     #%after:
12    
13     source /etc/sysconfig/rc
14     source $rc_functions
15     source /etc/conf.d/rdate
16    
17     if [[ -z ${RDATE_SERVER} ]]
18     then
19     echo "\$RDATE_SERVER not set ..."
20     exit 1
21     fi
22    
23     if [[ -z ${RDATE_TIMEOUT} ]]
24     then
25     echo "\$RDATE_TIMEOUT not set ..."
26     exit 1
27     fi
28    
29 niro 124 echo -e ${COLOREDSTAR}"Synchronizing clock with ${COLBLUE}${RDATE_SERVER}${COLDEFAULT} ..."
30 niro 123 rdate -s -t ${RDATE_TIMEOUT} ${RDATE_OPTS} ${RDATE_SERVER}
31     evaluate_retval
32    
33     update_svcstatus $1
34     splash svc_started "$(basename $0)" 0