Docker Name Resolution issues

  • Hi all,


    after a looooooong time I now upgraded to OMV 5.x and started with a fresh install, attached the old disks and got everyting running. Now I try to setup some of the more fancier plugins, but this time as containers (such as mariaDB for Kodi, nzbget and sickchill).


    I deployed the docker plugin and activated Portainer. I also then deployed mariaDB, imported my old KODI database and also got sickchill running and same for nzbget. I can download stuff, I can organize my TV shows and so on. Great.


    Now I have a problem getting sickchill connected to nzbget and other way around.


    Before I deployed a the two containers with Portainer, I created a new bridged network "media" where I put both containers in. I learned that I need this to enable host name resoltion for the containers.


    I also added the hostname for the containers inside the configuraition of Portainer.


    When I now try to ping from sickchill instance to nzbget everything works as expected:

    root@openmediavault:/Storage/appdata/nzbget/scripts# docker exec -ti sickchill ping nzbget

    PING nzbget (172.19.0.2): 56 data bytes

    64 bytes from 172.19.0.2: seq=0 ttl=64 time=0.158 ms

    64 bytes from 172.19.0.2: seq=1 ttl=64 time=0.193 ms

    64 bytes from 172.19.0.2: seq=2 ttl=64 time=0.187 ms

    64 bytes from 172.19.0.2: seq=3 ttl=64 time=0.186 ms


    Also connecting to the port works:

    root@openmediavault:/Storage/appdata/nzbget/scripts# docker exec -ti sickchill nc -zv nzbget 6789

    nzbget (172.19.0.2:6789) open


    However Sickrage allways complains about this error message:

    2021-01-22 14:29:16 WARNING :: SEARCHQUEUE-BACKLOG-95011 :: Please check your NZBget host and port (if it is running). NZBget is not responding to this combination


    The entry for sickrage is: nzbget:6789


    The only thing that does not work is nslookup of nzbget server. Even if ping and nc work.


    I then added /etc/hosts entries to the containers (via Portainer of cause) and that fixed it - it works. So at least now I have a workaround in place.


    However as the IP addresses assigned to the containers are simply random and not bound, so eventually the /etc/hosts entries will break some time in the future.


    I do NOT want to get host network using this and actually I am surprised why that does not work.


    Anyone has any idea on how to actually get this working properly? Anything I am missing?

    Everything is possible, sometimes it requires Google to find out how.

  • I had a similar issue a long time ago. For me it was because I placed the docker installation in another location besides the default /var/lib/docker. I think it was because I placed it on a share that I created instead of using the actual full filesystem path. This caused lots of rights issues and what was happening was the DNS resolver (resolv.conf) for the containers only gave the root user access to read the file. This caused DNS to fail entirely within the container unless the container was running as root. Not sure if this is your issue your not.


    If your containers are not running as root user, open a shell (or SSH) to your OMV server. Go to the location where you have docker configured for it's location (default is /var/lib/docker)...go to the containers folder go into the UID of the container you're having issues with, do an ls -l and make sure that that all have read rights. If not, your problem is AC/rightsL related.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!