How to setup IPs for dockers?

Recommended Posts

Try stopping and restarting the Docker service (see settings page). Upon starting the Docker service it should find all available networks  (br0 in your case) and make them available in the dropdown list for the container.


Have you created any custom (macvlan) networks manually in the past? If so, these need to be deleted as they will interfere with the automatic creation in unRAID 6.4.


Link to comment

The optional DHCP pool is used to defined a range of IP addresses for automatic assignment to containers in case a container is not given a fixed address. The range define here should not overlap which the IP range handed out by the regular DHCP server (usually your router) on the network.


When a DHCP pool is given, the network (br0) should also appear in the dropdown list.

What is the output of this command:

docker network ls


Link to comment

 docker network ls
NETWORK ID          NAME                DRIVER              SCOPE
fea497e4c33d        bridge              bridge              local
1e175f9bfa99        host                host                local
23bed2402df6        none                null                local

Link to comment

The command I listed is the same command which will be automatically executed when the docker service is started.


Somehow network creation fails for lovingHDTV and I like that seen confirmed. Usually it means you need to delete the docker image and recreate the containers.


Link to comment

Right, docker has the interface already internally assigned. Unfortunately there is (or I don't know) a way to release the interface other then deleting the docker image and recreate the containers. This sounds drastic, but recreation of containers is a simple and fast thing to do by selecting the already present templates after the new docker image has been created.


Link to comment
  • 2 weeks later...
On 11/5/2017 at 10:59 AM, ken-ji said:

While any containers using the docker network to be deleted are stopped, just issue

docker network rm dm-614e9ebdde75

to nuke the offending docker network.


I tested that but it doesn't work (docker tells the network is not existing and can't be deleted).


You'll need the sledgehammer approach :)  The following works:

rm /var/lib/docker/network/files/local-kv.db
/etc/rc.d/rc.docker restart

First the docker network file is deleted (it removes all known docker networks)

Next restart docker and networks are recreated, including the macvlan networks.

Link to comment
  • 2 months later...

I have previously been using pipeworks to assign unique IP's to a few dockers, I thought I would move to the new inbuilt option, it works fine talking to the new docker from my network, but those dockers are not able to see the host, or any other dockers on the host.


my subnet is and I am just entering the ip like


Another question, is the MAC address that gets assigned to a docker in this fashion static, if I wanted to use DHCP?


Am I missing something?

Link to comment

@ken-ji Thanks for the details, I guess I could look at setting up a VLAN, seems like an odd choice to be able to put a device on a LAN, but not have it talk to other device on the LAN (Host or otherwise). For the moment I'll just stick with pipeworks, it has been plodding along nicely for some time now.

Link to comment

@bonienl Was wondering if I could get some help with this. Server has a quad NIC, and I'd like to take one of those and use it for one specific container, leaving the rest as they are (at least for now). I set the eth1 interface up with a static IP, and I'm able to choose that interface in the container template. When I start the container I am able to ping it locally just fine, but it cannot reach the internet. I've been all over the forums looking for an answer, and I'm sure its just me missing something, but any help would be appreciated.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.