1
0

ntpd.hotplug-helper 221 B

12345678910111213
  1. #!/bin/sh
  2. while true
  3. do
  4. STATUS="$(/usr/sbin/ntpq -c 'rv 0 stratum'|awk -F '=' '{ print $2 }')"
  5. if [ -n "$STATUS" ] && [ "$STATUS" -lt "16" ]
  6. then
  7. ACTION="stratum" /sbin/hotplug-call ntp
  8. exit 0
  9. fi
  10. sleep 10
  11. done