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.

Problem with Host access to custom networks when network down

Featured Replies

Hi,
I have enabled "Host access to custom networks" in Docker settings which normally creates the shim-br0 macvlan bridge on boot.

But, if the physical network link is down (e.g. cable unplugged), the shim-br0 is not created on boot, causing routing problems between the containers (e.g. when using Nginx Proxy Manager reverse proxy logs report "No route to host")

I would understand this issue if I my Unraid would use DHCP, but my Unraid's network address, DNS and gateway is configured with STATIC addresses.

To fix, I would suggest to not start docker service on boot until physical network link is up (e.g. network cable is plugged in).

Any suggestions for a work-around in the meantime ?
Thanks for any help.

 

 


Edit: I found some code in the forum to manually create the shim-br0 bridge, but I am reluctant to use it because of the hard-coded IP ranges and implementation via cron. A more elegant approach to this problem would be nice.
 

ip link add shim-br0 link br0 type macvlan mode bridge
ip link set shim-br0 up
ip route add 192.168.1.0/25 dev shim-br0 
ip route add 192.168.1.128/25 dev shim-br0

 

Edited by brokenworld

  • 8 months later...

I have exactly the same problem.
Have you found any solution?

+1 Running into issues with Host access to custom networks on 6.11.5

  • 3 weeks later...

+2 Running into this issue. I tried disabling and then re-enabling Host access to custom networks and now i have the dreaded "Docker Service failed to start" Message. My next step is to delete and the re-create the image once i can get unraid to boot up again. this all started happening after my update to 6.11.5

  • 1 month later...

+3
Issue of unable to access 'Host network' from 'Docker network'.   
My usecase is from Ngix Proxy manager (172.17.0.9) to a local service running on a virtual IP (192.168.0.7).  From Ngix Docker I can ping the gateway (192.168.0.1) and other physical devices on the network) but cannot ping the docker VIP (192.168.0.7).

When stopping docker, turning off "Host access to custom networks", applying, turning on "Host access to custom networks", applying, allows host access again, until the next reboot. So it works, but has to be set at each reboot.  Is there a bug tracker where this can be logged?

Edited by isaw

+1 Again.

 

My server had a hard crash and upon restart I did the usual steps of both ensuring the shim-br0 network is up (via the commands from OP) as well as did the Docker toggle Host access to custom networks and now it is still failing.

 

EDIT: Ended up following this blog "UnraidOS host access to custom networks [Fix]" https://blog.siglerdev.us/unraidos/ which pointed me in the right direction. I forget that my network is 192.168.54.X not 192.168.1.X, so all I had to do was add the custom scripts plugin and add a script that runs the ip link code with the correct subnet. IE for me it had to be 54 when doing the ip link route add.

Edited by 97WaterPolo
Added my fix for the error

Thanks @97WaterPolo Added said userscript and away we go!  Happily working now.   

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.

Guest
Reply to this topic...

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.