Update ntpd.service

This commit is contained in:
wt committed 2025-07-25 17:33:19 +07:00
1 parent 87d86330da
commit 2505711edd
1 file changed
+5 -2
+5 -2
View File
@@ -5,11 +5,14 @@
. /usr/lib/init/init-funcs.sh
#------------------------------------
NTPD_OPTS=""
NTPD_OPTS="-N -p pool.ntp.org -n"
if [ -f /etc/ntp.conf ]; then
NTPD_OPTS="-N -n"
fi
start() {
notify "Starting ntpd"
/usr/bin/ntpd $NTPD_OPTS
/usr/bin/ntpd $NTPD_OPTS &
check $? "start ntpd"
echo $(pgrep ntpd) > /var/run/ntpd.pid
return $?