Closed LeWimbes closed 4 years ago
Hello,
I'm not sure what is causing the issue. I don't personally use Pi-hole so I don't currently have an easy example to compare it to.
One thing that stands out is the so-rcvbuf
error warning you showed is likely unrelated. That's a performance setting, related to kernel buffer. It looks like your device was trying to request more resources than permitted by the OS. It still got some so the container should have been able to start.
I don't see anything in the errors that would make me think it would be port related. Could you increase the logging verbosity to see if that shows more?
Also, you might also read through the following two closed issues:
First of all: Thank you for your replay.
Actually increasing the logging verbosity revealed one/two error:
[1599155750] unbound[1:0] error: could not read root hints /var/lib/unbound/root.hints: No such file or directory
[1599155750] unbound[1:0] error: Could not set root or stub hints
But I don't understand why unbound can't find that file. As you can see in my docker compose file I am mounting ./unbound/setup/root_hints/
on /var/lib/unbound/
. And in the root_hints
directory is my root.hints
file:
x@y:/a/b/docker/unbound/setup/root_hints $ ls
root.hints
If I comment out the root.hints line no error occurs and unbound starts.
My initial thought is root hints is being mounted in the wrong location. Unbound runs in a chroot.
On Thu, Sep 3, 2020, 1:12 PM LeWimbes notifications@github.com wrote:
First of all: Thank you for your replay.
Actually increasing the logging verbosity revealed one/two error:
[1599155750] unbound[1:0] error: could not read root hints /var/lib/unbound/root.hints: No such file or directory [1599155750] unbound[1:0] error: Could not set root or stub hints
But I don't understand why unbound can't find that file. As you can see in my docker compose file I am mounting ./unbound/setup/root_hints/ on /var/lib/unbound/. And in the root_hints directory is my root.hints file:
x@y:/a/b/docker/unbound/setup/root_hints $ ls root.hints
If I comment out the root.hints line no error occurs and unbound starts.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/MatthewVance/unbound-docker-rpi/issues/4#issuecomment-686662617, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAUMHOR4ZYZVKSQ6T3ZPWRTSD7L7HANCNFSM4QPGN3XA .
Hmm... I've now simply put the root.hints
file in the same folder as my unbound.conf
. It seams to work so far.
For anyone who is having this problem (even on non Docker) the solution is to edit the /etc/sysctl.conf
file and add this line somewhere in the file:
net.core.rmem_max=1048576
After I rebooted, you can now run sudo service unbound status
and no more error! I'm posting the solution here since this is the first thing that shows up on google when you search for it hope that's okay
@Telesphoreo thanks for sharing.
just got here a year later looking for this issue. the current docker image does not have the sysctl.conf file nor the sysctl command. My thought on a solution was to run -- sysctl -w net.core.rmem_max=4194304 with the command: key in docker compose. Can't run it without the sysctl command.
add: cap_add: NET_ADMIN to the docker file for unbound. It solved this issue for me
Hi, I was trying to setup your unbound image along my already running Pi-hole. When I try to start all the services with
sudo docker-compose up
, unbound returns the following message and exits:On the Pi-hole discourse site I found a post dealing with the same issue https://discourse.pi-hole.net/t/pihole-on-ubuntu-18-04-with-unbound-fails-after-some-time/22585, but it seems like using different ports isn't solving the issue in my case.
In my setup I mostly followed this guide: https://docs.pi-hole.net/guides/unbound/
This is my current
unbound.conf
:And the probably relevant part of my
docker-compose.yml
:I would really appreciate your help finding the cause of this issue. Thank you :)