Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Docker Container - Network Bridge, No Container Resolution on 127.0.0.11

Featured Replies

  • Community Expert

I think the title pretty much says it all really.

 

I can ping 127.0.0.11 however if I dig like

 

dig @127.0.0.11 mariadb

 

I get nothing back, it just times out trying to connect to the DNS server.

 

I should mention that all external DNS resolution works and is passed though to my router (when not trying to resolve a local container name directly).

 

This seems like a basic part of Docker, but I am unsure where to look next.

 

At this stage, I am not even sure how the image is being given my hosts DNS, the resolve.conf is empty.

 

Hoping someone can point me in the right direction.

127.0.0.11 is the embedded docker dns resolver for containers. It can only be accessed within containers and is mainly for resolving linked containers

what container are you using that's giving you issues and how?

  • Author
  • Community Expert

Ken-jl, are you saying the docker resolver 127.0.0.11 only works with containers not in bridge mode?

 

I have a proftpd container, configured for mysql authenication.

 

I have a mariadb container, called mariadb.

 

From the proftpd container, I was expecting to be able to dig @127.0.0.11 for mariadb, and get a response back like 172.15.0.3 for example.

 

Is this not how it should work?

Hmm that's seems to be the correct behavior.

Is your proftpd container network-linked to the mariadb?

ie did you create a custom docker network and then connect the proftpd and mariadb to that?

on the default bog standard bridge network its not going to work

otherwise it should work like this.

root@MediaStore:~# docker network create bridge2
89bbdd77e82561fb7223055c3f6c1bdf6092e66241c10f4c0172cb2b6cc9bcec
root@MediaStore:~# docker run -d --network bridge2 --name box1 --rm alpine:latest sleep 3600
6fb56d0ef4ab42060930b1a01108467f5e26b61e52d212d16ff7e6158a1afee0
root@MediaStore:~# docker run -d --network bridge2 --name box2 --rm alpine:latest sleep 3600
28f4f19fd5e1c48832340b5639dd8abbd979f1909a5877cc367590fc54eae1be
root@MediaStore:~# docker exec box1 nslookup box2
Server:         127.0.0.11
Address:        127.0.0.11:53

Non-authoritative answer:
*** Can't find box2: No answer

Non-authoritative answer:
Name:   box2
Address: 172.19.0.3

root@MediaStore:~# docker exec box2 nslookup box1
Server:         127.0.0.11
Address:        127.0.0.11:53

Non-authoritative answer:
*** Can't find box1: No answer

Non-authoritative answer:
Name:   box1
Address: 172.19.0.2

How this maps in the GUI is beyond me.

  • Author
  • Community Expert

Hmm this is interesting, thanks for the example.

 

the reason i don't normally create a custom network, is that I still want it accessible from the main hosts IP (so the mariadb accessible by other machines on the network)

 

I guess my next next is to test it in this configuration.

Thank you!

I will feedback / mark solved once tested (maybe a couple days)

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.