From 82801016ac95898cd4fb8109dc233af995ec7291 Mon Sep 17 00:00:00 2001 From: Wai Yee Wong Date: Tue, 14 Dec 2021 17:57:02 -0500 Subject: [PATCH] Do not write the pid of chronyd to /dev/null for all distros --- xCAT/postscripts/setupntp | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/xCAT/postscripts/setupntp b/xCAT/postscripts/setupntp index c0466607a..eaae4a8b0 100755 --- a/xCAT/postscripts/setupntp +++ b/xCAT/postscripts/setupntp @@ -168,15 +168,6 @@ warn_if_bad "$?" "Failed to configure the system to maintain the RTC in universa # Synchronize and set the system clock once logger -t $log_label -p local4.info "Syncing the clock ..." -if [ -f /etc/os-release ] && cat /etc/os-release |grep NAME|grep Ubuntu>/dev/null -then - # Some versions of chronyd on Ubuntu distros have an issue - # with the valid option "pidfile /dev/null". - pidfile_option="" -else - pidfile_option="pidfile /dev/null" -fi - chronyd -f /dev/null -q "$( if [ "${#NTP_SERVERS[@]}" -gt "0" ] then @@ -184,7 +175,7 @@ chronyd -f /dev/null -q "$( else echo "pool pool.ntp.org iburst" fi -)" "$pidfile_option" +)" rm -f /etc/adjtime # Set the hardware clock from the system clock