Magellan Linux

Annotation of /trunk/rdate/rdate.rc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 123 - (hide annotations) (download)
Mon Mar 26 19:18:49 2007 UTC (17 years, 1 month ago) by niro
File size: 615 byte(s)
- added rdate rc script and configuration

1 niro 123 #!/bin/bash
2     # $Header: /root/magellan-cvs/src/rdate/rdate.rc,v 1.1 2007-03-26 19:18:49 niro Exp $
3    
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     echo -e ${COLOREDSTAR}"Synchronizing clock with ${RDATE_SERVER} ..."
30     rdate -s -t ${RDATE_TIMEOUT} ${RDATE_OPTS} ${RDATE_SERVER}
31     evaluate_retval
32    
33     update_svcstatus $1
34     splash svc_started "$(basename $0)" 0