Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: Can chronyd be called with "-r -s" args? (Read 870 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Can chronyd be called with "-r -s" args?

Hello !

Originally /etc/dinit.d/chronyd comes with just -n arg, however according to https://wiki.archlinux.org/title/Chrony#Example:_intermittently_running_desktops -r -s are required if one wants to correct RTC at boot from deviations.  For systemd there's a config file /etc/sysconfig/chronyd which helps with chronyd additional args, and if something like that was available that would also be great.  For those options to work  some additional configuration on /etc/chrony.conf is required.

So perhaps something can be done.  For now, I have just modified how the daemon is called on /etc/dinit.d/chronyd, and if the it doesn't get overwritten on upgrades (*.pacnew versions of the file get generated) then that's more than enough, but I don't know if that's the case.

Greetings !

Re: Can chronyd be called with "-r -s" args?

Reply #1
See NoUpgrade in pacman.conf.

Re: Can chronyd be called with "-r -s" args?

Reply #2
chrony-dinit has been updated to 20250722 to reflect the /etc/sysconfig/chronyd ability, wait for it to hit your repos. Thanks for the report.
now only the dinit guy in artix

 

Re: Can chronyd be called with "-r -s" args?

Reply #3
chrony-dinit has been updated to 20250722 to reflect the /etc/sysconfig/chronyd ability, wait for it to hit your repos. Thanks for the report.

Yay:

Code: [Select]
% pacman -Qs chrony-dinit
local/chrony-dinit 20250722-1 (dinit-world)
    dinit service scripts for chrony

% pacman -Ql chrony-dinit
chrony-dinit /etc/
chrony-dinit /etc/dinit.d/
chrony-dinit /etc/dinit.d/chrony
chrony-dinit /etc/dinit.d/chronyd
chrony-dinit /usr/
chrony-dinit /usr/lib/
chrony-dinit /usr/lib/dinit/
chrony-dinit /usr/lib/dinit/chronyd

% bat /etc/dinit.d/chronyd
type            = process
command         = /usr/lib/dinit/chronyd
smooth-recovery = true
depends-on      = network.target
depends-on      = local.target

% bat /usr/lib/dinit/chronyd
#!/bin/sh
[ -r /etc/sysconfig/chronyd ] && . /etc/sysconfig/chronyd
exec /usr/bin/chronyd -n $OPTIONS

Very cool !   Thanks a lot !