Drop 50ntpd

ntpd operates normally over a sleep/wake cycle. Stoppping and
restarting it in a sleep hook is too adhoc. If it is essential
that ntpd be stopped and restarted, then having NetworkManager
do the job when interfaces go offline and come back online is
a better way to do things.
---
 pm/sleep.d/50ntpd |   28 ----------------------------
 1 files changed, 0 insertions(+), 28 deletions(-)

diff --git a/pm/sleep.d/50ntpd b/pm/sleep.d/50ntpd
deleted file mode 100755
index 96ad3d4..0000000
--- a/pm/sleep.d/50ntpd
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/bin/sh
-
-. "${PM_FUNCTIONS}"
-
-NTPD_LOCK="pm-ntpd.lock"
-
-stop_ntp()
-{
-       if try_lock "${NTPD_LOCK}"; then
-               trap 'release_lock "${NTPD_LOCK}"' 0
-               stopservice ntpd
-       fi
-}
-
-start_ntp()
-{
-       # Bring back ntpd _after_ NetworkManager and such come back...
-       ( spin_lock "${NTPD_LOCK}";
-       trap 'release_lock "${NTPD_LOCK}"' 0
-       sleep 20
-       restartservice ntpd; ) &
-}
-
-case "$1" in
-       hibernate|suspend) stop_ntp ;;
-       thaw|resume) start_ntp ;;
-       *) exit $NA ;;
-esac
-- 
1.6.0.4

_______________________________________________
Pm-utils mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/pm-utils

Reply via email to