aboutsummaryrefslogtreecommitdiffstats
path: root/50-ntpdate
blob: 0c6f5b49b9fa62b819637a932b5e97d3764976b0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh
 
case "${reason}" in
	BOUND|REBIND|REBOOT|RENEW|TIMEOUT|STATIC)
		# sync time as soon as connection is up
		# this reads nameserver from /etc/ntp.conf
		ntpd -q
		# alternatively use ntpdate and give hostname
		#ntpdate -u pool.ntp.org
		;;
	PREINIT|EXPIRE|INFORM|FAIL|IPV4LL|NAK|NOCARRIER|RELEASE|STOP)
		# do nothing here...
		;;
esac