You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Issue Description:
Our NTP configuration is based on the guidelines provided in the SONiC documentation https://github.com/sonic-net/SONiC/blob/master/doc/ntp/ntp-design.md
Facing issue in synchronizing the NTP server with the client on our system. This problem was identified when reviewing the NTP logs, which indicated a time error, specifically stating that the clock is unsynchronized.
Output of show ntp:
NTP Status Details:
Output of ntpq -p server ip_address
command used to generate the NTP logs:
sudo journalctl -u ntp
Logs:
Jun 19 01:40:35 sonic ntpd[12168]: proto: precision = 0.098 usec (-23)
Jun 19 01:40:35 sonic ntpd[12168]: basedate set to 2019-08-28
Jun 19 01:40:35 sonic ntpd[12168]: gps base set to 2019-09-01 (week 2069)
Jun 19 01:40:35 sonic ntpd[12168]: restrict 0.0.0.0: KOD does nothing without LIMITED
Jun 19 01:40:35 sonic ntpd[12168]: Listen normally on 0 lo 127.0.0.1:123
Jun 19 01:40:35 sonic ntpd[12168]: Listen normally on 1 eth0 172.30.25.103:123
Jun 19 01:40:35 sonic ntpd[12168]: Listening on routing socket on fd #18 for interface updates
Jun 19 01:40:35 sonic ntpd[12168]: kernel reports TIME_ERROR: 0x41: Clock Unsynchronized
Jun 19 01:40:35 sonic ntpd[12168]: kernel reports TIME_ERROR: 0x41: Clock Unsynchronized
Jun 19 01:40:35 sonic ntp-systemd-wrapper[12162]: Starting NTP server in default-vrf: ntpd
Jun 19 01:40:35 sonic systemd[1]: Started Network Time Service.
Additional Information:
All necessary services (ntp, hostcfgd, ntp-config) have been confirmed to be running.
The server ip address is reachable via ping.
Expected Outcome:
Successful synchronization with the configured NTP server.
I am seeking community assistance to identify any potential misconfigurations or issues that may be causing the problem.
The text was updated successfully, but these errors were encountered:
Purnimayeggina
changed the title
Unable to Sync NTP with Server IP Address
Issue with NTP Server Synchronization - Clock Unsynchronized
Feb 13, 2024
I haven't been able to fully dig through the issue, but it may be related to how /etc/ntp.conf is being generated. The switch I am testing on does not have a management interface (eth0) and even after adding Loopback0 with an IP it does not work as described in the NTP template.
As a workaround, I was able to manually update the source interface in the config. That seems to do the trick and allows NTP to sync.
On our chassis, when I looked at /etc/ntpsec/ntp.conf, the server config was missing. Looks like based on the sonic-mgmgt generated minigraph, some if checks in ntp.conf.j2 did not satisfy the addition of server config.
The changes in PR #18736 helped fix this issue for us.
From sonic-mgmt, I am trying to figure out how we can set the config like iburst which is required to speed up clock sync. Without that, it takes around 1.5 to 2 mins on our chassis to sync the clock.
Issue Description:
Our NTP configuration is based on the guidelines provided in the SONiC documentation https://github.com/sonic-net/SONiC/blob/master/doc/ntp/ntp-design.md
Facing issue in synchronizing the NTP server with the client on our system. This problem was identified when reviewing the NTP logs, which indicated a time error, specifically stating that the clock is unsynchronized.
Output of show ntp:

NTP Status Details:

Output of ntpq -p server ip_address
command used to generate the NTP logs:
sudo journalctl -u ntp
Logs:
Jun 19 01:40:35 sonic ntpd[12168]: proto: precision = 0.098 usec (-23)
Jun 19 01:40:35 sonic ntpd[12168]: basedate set to 2019-08-28
Jun 19 01:40:35 sonic ntpd[12168]: gps base set to 2019-09-01 (week 2069)
Jun 19 01:40:35 sonic ntpd[12168]: restrict 0.0.0.0: KOD does nothing without LIMITED
Jun 19 01:40:35 sonic ntpd[12168]: Listen normally on 0 lo 127.0.0.1:123
Jun 19 01:40:35 sonic ntpd[12168]: Listen normally on 1 eth0 172.30.25.103:123
Jun 19 01:40:35 sonic ntpd[12168]: Listening on routing socket on fd #18 for interface updates
Jun 19 01:40:35 sonic ntpd[12168]: kernel reports TIME_ERROR: 0x41: Clock Unsynchronized
Jun 19 01:40:35 sonic ntpd[12168]: kernel reports TIME_ERROR: 0x41: Clock Unsynchronized
Jun 19 01:40:35 sonic ntp-systemd-wrapper[12162]: Starting NTP server in default-vrf: ntpd
Jun 19 01:40:35 sonic systemd[1]: Started Network Time Service.
Additional Information:
All necessary services (ntp, hostcfgd, ntp-config) have been confirmed to be running.
The server ip address is reachable via ping.
Expected Outcome:
Successful synchronization with the configured NTP server.
I am seeking community assistance to identify any potential misconfigurations or issues that may be causing the problem.
The text was updated successfully, but these errors were encountered: