Bug 444821

Summary: Enabling "set date and time automatically" stops "ntpd.service" rather than starting it
Product: [Applications] systemsettings Reporter: Alberto Salvia Novella <es20490446e>
Component: kcm_clockAssignee: Paul Campbell <paul>
Severity: normal CC: nate, nicolas.fella, plasma-bugs
Priority: HI    
Version: 5.22.5   
Target Milestone: ---   
Platform: Manjaro   
OS: Linux   
Latest Commit: Version Fixed In:

Description Alberto Salvia Novella 2021-11-02 12:05:52 UTC
1. sudo systemctl start ntpd
2. systemctl status ntpd
3. Date & Time -> "Set date and time automatically"
4. systemctl status ntpd

"ntpd.service" has been deactivated.

Same the other way around: activating "ntpd.service" disables the box "set date and time automatically".

In reality the box is only intended to sync the time once. But that's not what the wording suggests, neither it's the most functional thing to do. It should instead enable ntpd.
Comment 1 Nate Graham 2021-11-08 17:53:22 UTC
lol can confirm!
Comment 2 Nicolas Fella 2021-11-08 21:28:07 UTC
What that checkbox does is control systemd-timesyncd (if available). Presumably systemd-timesyncd disables ntpd when activated since it would be a competing service
Comment 3 Nicolas Fella 2021-11-08 23:26:38 UTC
Sorry, slight correction to the above:

The checkbox uses the org.freedesktop.timedate1 interface (systemd-timedated) to control the NTP settings. This then activates the configured NTP implementation, which on Manjaro is systemd-timesyncd. So ntpd is still getting replaced in favor of systemd-timesyncd since that's what the system is configured to do
Comment 4 Nicolas Fella 2021-11-08 23:28:53 UTC
See https://www.freedesktop.org/software/systemd/man/systemd-timedated.service.html for details on timedated and how to configure which NTP daemon is used
Comment 5 Alberto Salvia Novella 2021-11-09 18:16:22 UTC
Thanks for the info. Very valuable.