]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blob - src/initscripts/init.d/setclock
Enabled force setting system time on boot.
[people/pmueller/ipfire-2.x.git] / src / initscripts / init.d / setclock
1 #!/bin/sh
2 ########################################################################
3 # Begin $rc_base/init.d/setclock
4 #
5 # Description : Setting Linux Clock
6 #
7 # Authors : Gerard Beekmans - gerard@linuxfromscratch.org
8 #
9 # Version : 00.00
10 #
11 # Notes :
12 #
13 ########################################################################
14
15 . /etc/sysconfig/rc
16 . ${rc_functions}
17
18 CLOCKPARAMS=
19
20 case ${1} in
21 start)
22 boot_mesg "Setting system clock..."
23 hwclock --hctosys ${CLOCKPARAMS} &>/dev/null
24 evaluate_retval
25 ;;
26
27 stop)
28 boot_mesg "Setting hardware clock..."
29 hwclock --systohc ${CLOCKPARAMS} &>/dev/null
30 evaluate_retval
31 ;;
32
33 *)
34 echo "Usage: ${0} {start}"
35 ;;
36
37 esac