Spitz Plus local NTP sync?

Hi,

If I want my Spitz Plus to sync its time with a local (on the LAN) NTP server, is it only possible by editing:

/etc/config/system

config system
option timezone 'xyz’
option ntp_enabled '1'
option ntp_server 'ip-address’

Is this the correct way/configuration?

Thanks

That way may not necessarily be 'wrong' but I'd undo the editing to the conf. Per the OWRT Wiki:

By default, NTP client is enabled and NTP server is disabled. Enable server mode:

uci set system.ntp.enable_server='1'
uci commit system
/etc/init.d/sysntpd restart

Speaking of NTP you should consider adding the corresponding upstream IPs to the DNS addresses. DNS can cause some problems in certain common scenarios.

uci set system.@timeserver[0].server='0.openwrt.pool.ntp.org 1.openwrt.pool.ntp.org 2.openwrt.pool.ntp.org 3.openwrt.pool.ntp.org 104.167.241.197 73.239.145.47 142.147.88.111 171.66.97.126'
uci set system.@timeserver[0].use_dhcp='0'
uci commit system

Thank you for taking the time to respond.

I might be missing something, but wouldn’t enabling “server” make the Spitz Plus act as an NTP server to other clients? I only want it to sync with a local GPS stratum 1 NTP time source on the LAN.

HAH! Silly me; I misread your OP as if you wanted you Spitz Plus to be the NTP server for downstream clients! Here you go:

myNTPServerIPHere='< my NTP server IP here >' # keep the quote marks
uci set system.@timeserver[0].server="{$myNTPServerIPHere}"
uci commit system
/etc/init.d/sysntpd restart

The IP should be reflected in LuCI -> System -> System -> Time Synchronization.

2 Likes

Yes, this sounds like it :slightly_smiling_face:
Easy and straightforward. Thanks.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.