Failed to adjust time during NTP sync: Insufficient permissions

The virtualization environment of your choice does not permit setting the hosts time. This is nothing that could be fixed from within the virtualization itself.
You can disable NTP syncing using sudo pihole-FTL --config ntp.sync.interval 0

Wird es eine Möglichkeit geben um die sync im lxc container zu erhalten?

Building a container for every special branch would probably be overkill, but you can locally build a docker image with the new build.sh script on the development-v6 branch (I use this for testing quite regularly):

https://github.com/pi-hole/docker-pi-hole/tree/development-v6?tab=readme-ov-file#building-the-image-locally

In this case one would locally clone the repo, switch to development-v6 branch and run ./build.sh -f tweak/ntp_delay

1 Like

Thanks!
luck will have it that I pulled the then latest v6-development docker image 2 days ago and the problem is gone, did the delay get into that branch around that period? It could explain I guess...

No, the delay branch is still under review. We are currently working on another feature and have two PRs on hold while this is ongoing.

1 Like

It has just been merged.

Fix for the problem under proxmox LXC

Set the container to Previligated otherwise the container would have the missing permissions

Everyone who has the container set to unprivileged has the error

changing helps

my settings:

I am not a Proxmox expert, so I might be wrong...

However, I wouldn't recommend setting the container as privileged, since you might introduce a vulnerability to your host by doing so.

By default, your Proxmox host should already have working NTP synchronization, and your LXC containers get the time from your host. I believe that if you set the container to privileged, Pi-hole will also attempt to update the time on the host, which is not necessary since the host already does that. So all you accomplish by setting the container as privileged is introducing a potential vulnerability to your entire host/cluster.

So, in my opinion, the best fix for this is to simply empty the ntp.sync.server and set the ntp.sync.interval to 0, as mentioned in the marked solution by DL6ER.

2 Likes

I agree.

The best solution would be if pihole_ftl checks the permission.

If ntp is possbile -> continue
If not -> disable it and generate a warning about that, explaining why.

So, in my opinion, the best fix for this is to simply empty the ntp.sync.server and set the ntp.sync.interval to 0 , as mentioned in the marked solution by DL6ER.

when i remove server name i get this errror

Cannot resolve NTP server address: Name does not resolve ""

Disabling this option fixes everything.


It still allows Pi-hole to serve NTP but not go to the server to try to sync its own time with it. I guess the possibility of the host driting is possible, but in that case you can disable it acting like an NTP server on IPV4&6.

1 Like

For Proxmox LXC Debian
apt install ntp

I had no further problem and can ignore the error as:

timedatectl status

Local time: Thu 2025-03-13 18:09:49 AEDT
Universal time: Thu 2025-03-13 07:09:49 UTC
RTC time: n/a
Time zone: Australia/Canberra (AEDT, +1100)
System clock synchronized: yes
NTP service: n/a
RTC in local TZ: no

Which was at the time... correct

are you needed to do dpkg-reconfigure tzdata initial???

I did this, but still getting the error at reboot in Pi-hole. The lxc has the right time tho.

ntp will keep the correct time in the container so you can just ignore it

Gotcha, thanks.
Disabled the pi-hole side and will sleep tonight with no errors :slight_smile:

Do NOT forget apt update && apt upgrade afterwards my solution was to disable any ntp checks and dpk-reconfigure tzdata, than reboot and enjoy