Debugging a strange permission issue on Unbound
- Posted on
- 5 mins read
I recently upgraded a VM from Debian 9 to Debian 10 and found myself unable to start Unbound.
This is not uncommon when “dist-upgrading” and my experience told me it would probably not be a big deal, but the error message was quite a surprise:
unbound[429:0] error: Could not open /etc/unbound/unbound.conf: Permission denied
unbound[429:0] fatal error: Could not read config file: /etc/unbound/unbound.conf. Maybe try unbound -dd, it stays on the commandline to see more errors, or unbound-checkconf
Let’s see what the permissions are on that file:
# ls -ld /etc /etc/unbound /etc/unbound/unbound.conf
drwxr-xr-x 93 root root 4096 Jun 4 14:22 /etc
drwxr-x--- 3 unbound unbound 4096 May 29 06:03 /etc/unbound
-rw-r----- 1 unbound unbound 94 May 17 02:10 /etc/unbound/unbound.conf
Ok, that’s strange!