Ntpd-rs not touching system clock

Is it possible to NOT let ntpd-rs touch system clock?

I try to set up a nts server jo join this project. The server is a lxc container and should not mess with the system clock of the host. Right not the service fails to start:

ERROR ntpd::daemon::system: Could not control clock: Insufficient permissions to interact with the clock.

Typical, no you can’t.

But then, a VPS-container should never be able to touch the system-hardware-clock.

Also, there is not need, as the container has it’s own system-clock, not being hardware.

Virtualisation will and should never let you touch the hardware-clock.

So the answer is: NO.

I know, I agree 100. But still it IS trying to control system clock. How to disable? It is possible with chrony.

You install chrony in the VPS, then edit /etc/default/chrony to look like this:

DAEMON_OPTS="-F 1 -x"

Then restart chrony and it should stop controlling the clock.

If that doesn’t help you may need to # this line too like below:

# This directive enables kernel synchronisation (every 11 minutes) of the
# real-time clock. Note that it can’t be used along with the 'rtcfile' directive.
# rtcsync

This works for me in any VPS I have running.

Thanks, but im not asking about chrony.

Sorry, read too fast.

For ntp, try this in the ntp.conf:

# ntp_adjtime: Operation not permitted
disable kernel
1 Like