#!/bin/sh /etc/rc.common
START=70
SERVER=$(uci -q get system.ntp.server | tr -d '\n')
start() {
{
while ! ping -c1 $SERVER >/dev/null 2>&1; do sleep 60; done
/usr/sbin/ntpclient -s -l -h $SERVER >/dev/null 2>&1;
} &
}
stop() {
killall ntpclient