The ntpd.sock file is created with only user and group rw permissions (for root:root), so that for the end user, ntpctl fails: $ ntpctl -s all ntpctl: connect: /var/lib/openntpd/run/ntpd.sock: Permission denied There's no good reason to become root just for that (with ntp, there's no need to be root to get similar information via ntpdc).
tags -1 +confirmed +upstream thanks Hi Vincent! I'm double-checking this with upstream, since the implementation of openntpd goes far on resctricting quite a lot some security concerns on this socket file. Moreover, the code seems to have been approaching this socket as a control socket, which implies that there could be some controlling capabilities around ntpd daemon (to be set in place in the future, not right now). Bare with me a little bit more. Cheers, Dererk ps: sorry about the delay
Can this still be reproduced with 6.8p1-1 in Debian/unstable? Martin-Éric
zira:~> ll /var/lib/openntpd/run/ntpd.sock srw-rw---- 1 root root 0 2016-11-05 11:13:44 /var/lib/openntpd/run/ntpd.sock= zira:~> ntpctl -s all ntpctl: connect: /var/lib/openntpd/run/ntpd.sock: Permission denied So I've purged the package and reinstalled it, but got Setting up openntpd (1:6.8p1-1) ... /usr/lib/sysusers.d/openntpd.conf:1: Unknown modifier 'u!'. dpkg: error processing package openntpd (--configure): old openntpd package postinst maintainer script subprocess failed with exit status 1 Processing triggers for man-db (2.13.1-1) ... Errors were encountered while processing: openntpd Error: Sub-process /usr/bin/dpkg returned an error code (1) Concerning this error, I reported https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1134578 Now, zira:~> ll /var/lib/openntpd/run/ntpd.sock ls: cannot access '/var/lib/openntpd/run/ntpd.sock': No such file or directory zira:~> ntpctl -s all ntpctl: connect: /var/lib/openntpd/run/ntpd.sock: No such file or directory but this may be due to the above error.
I could try on a more recent machine: disset:~> ll /var/lib/openntpd/run/ntpd.sock srw-rw---- 1 root root 0 2026-04-22 01:59:04 /var/lib/openntpd/run/ntpd.sock= disset:~> ntpctl -s all ntpctl: connect: /var/lib/openntpd/run/ntpd.sock: Permission denied
Thanks. Could you file a bug report upstream (https://github.com/openntpd-portable/openntpd-portable/issues)? He recently resumed development, so hopefully he will respond to it. Martin-Éric
Control: forwarded -1 https://github.com/openntpd-portable/openntpd-portable/issues/83 OK, done.