RTC battery and ntp

The time on my Rock 5B is wrong:

$ timedatectl
               Local time: Tue 2023-06-27 01:16:12 UTC
           Universal time: Tue 2023-06-27 01:16:12 UTC
                 RTC time: Tue 2023-06-27 01:16:13
                Time zone: UTC (UTC, +0000)
System clock synchronized: no
              NTP service: active
          RTC in local TZ: no

This is about three days behind the actual date and time.

`timesyncd1 is running, but does not say it has sync’ed:

$ sudo systemctl status systemd-timesyncd
● systemd-timesyncd.service - Network Time Synchronization
     Loaded: loaded (/lib/systemd/system/systemd-timesyncd.service; enabled; vendor preset: enabled)
     Active: active (running) since Tue 2023-06-27 01:05:28 UTC; 12min ago
       Docs: man:systemd-timesyncd.service(8)
   Main PID: 408 (systemd-timesyn)
     Status: "Idle."
      Tasks: 2 (limit: 18844)
     Memory: 1.1M
        CPU: 465ms
     CGroup: /system.slice/systemd-timesyncd.service
             └─408 /lib/systemd/systemd-timesyncd

Mar 20 14:32:08 stake02 systemd[1]: Starting Network Time Synchronization...
Mar 20 14:32:08 stake02 systemd-timesyncd[408]: System clock time unset or jumped backwards, restoring from recorded timestamp: Tue 2023-06-27 01:05:28 UTC
Jun 27 01:05:28 stake02 systemd[1]: Started Network Time Synchronization.
Jun 27 01:05:33 stake02 systemd-timesyncd[408]: Network configuration changed, trying to establish connection.
Jun 27 01:05:35 stake02 systemd-timesyncd[408]: Network configuration changed, trying to establish connection.
Jun 27 01:05:39 stake02 systemd-timesyncd[408]: Network configuration changed, trying to establish connection.

I have no battery connected for the RTC and was disappointed to learn the board didn’t ship with one. Do I need one if network time is running properly? I will want the time to be correct early in the boot sequence.

How do I get network time sync’ed on boot without using the RTC?

Have you tried:

sudo systemctl restart systemd-timesyncd

I had time keeping related issues with my board. Getting an RTC battery fixed them.

Do you have chronie installed?

1 Like