getumbrel / umbrel

A beautiful home server OS for self-hosting with an app store. Buy a pre-built Umbrel Home with umbrelOS, or install on a Raspberry Pi or any x86 system.
https://umbrel.com
Other
7.21k stars 522 forks source link

NTP Time sync did not work, rendering Umbrel OS unusable #1763

Closed KHP86 closed 6 months ago

KHP86 commented 6 months ago

NTP Time sync didn't work after both RPi4 update install and fresh install. This caused time errors with github servers (certificate validity issue) and failure to fetch app manifests. This rendered the whole Umbrel OS unusuable.

To fix:

In the "/etc/systemd/timesyncd.conf" file. I had to add a NTP Server and uncomment "FallbackNTP" parameter.

Installed "systemd-timesyncd". "sudo apt install systemd-timesyncd"

Enabled NTP time sync. "sudo timedatectl set-ntp true"

This problem was observed in Umbrel OS v1.0.

lukechilds commented 6 months ago

Hey @KHP86 great spot, thanks for your help with this!

We use ntpd for time sync not systemd-timesyncd. It seems to be working correctly but there is a race condition where if umbreld starts quickly it can make network requests before the sync has completed which fail.

We've updated umbreld to wait for ntp sync to complete before it starts anything that needs to interact with the network: https://github.com/getumbrel/umbrel/commit/5a84a1af2bdc8921f7aa220a8c109266407884fd

Thanks again!

KHP86 commented 6 months ago

Awesome! Thanks for fixing!