Skip to content

Commit a57cb14

Browse files
committed
[ntp] disable ntp time jump (sonic-net#2589)
- removing -g to disable jump when time difference is greater than 1000s - add -x to disable initial jump
1 parent 2a12684 commit a57cb14

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

build_debian.sh

+4
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,10 @@ sudo mv $FILESYSTEM_ROOT/grub-pc-bin*.deb $FILESYSTEM_ROOT/$PLATFORM_DIR/x86_64-
263263
## Disable kexec supported reboot which was installed by default
264264
sudo sed -i 's/LOAD_KEXEC=true/LOAD_KEXEC=false/' $FILESYSTEM_ROOT/etc/default/kexec
265265

266+
## Modifty ntp default configuration: disable initial jump (add -x), and disable
267+
## jump when time difference is greater than 1000 seconds (remove -g).
268+
sudo sed -i "s/NTPD_OPTS='-g'/NTPD_OPTS='-x'/" $FILESYSTEM_ROOT/etc/default/ntp
269+
266270
## Fix ping tools permission so non root user can directly use them
267271
## Note: this is a workaround since aufs doesn't support extended attributes
268272
## Ref: https://github.com/moby/moby/issues/5650#issuecomment-303499489

0 commit comments

Comments
 (0)