Ubuntu – No route to host error when trying to login in a public wifi hotspot

networkingwireless

I'm using Ubuntu 18.04.2 LTS, kernel version 4.15.0-47-generic.
In the office we have a public wifi hotspot. However, when I connect, I have to accept some terms and conditions before I can use the internet. This does not work on Ubuntu though, I get an "No route to host" error message for this page.

  • It works when I reboot and accept the terms and conditions in Windows, then reboot again to Ubuntu. I can directly connect.
  • For other wifi hotspots (at the airport or hotels) I don't have this problem. So this only occurs for this one wifi hotspot.
  • I've already checked the URL for the login page I get forwarded to, which is correct.
  • I've tried setting DNS servers manually in nm-connection-editor (using the DNS hosts that are used on my Windows machine for this hotspot), without success
  • I've tried sudo dpkg-reconfigure resolvconf, without success

What can I do to find and fix the issue such that I can login and connect on this wifi hotspot as well?

Best Answer

Finally, I found the issue. The problem was the docker daemon creating network bridges that claimed the subnetwork 172.16.0.0, 172.17.0.0, ... and the wifi-hotspot-service I needed to connect to had an IP that was in one of the above subnetworks.

What helped me:

  • Remove the docker containers I didn't need anymore
  • Run sudo docker network prune to delete unused docker networks
  • Change the default docker0 bridge IP address (in my case docker was installed via snap, i.e. add "bip": "192.168.154.1/24", to the file /var/snap/docker/current/config/daemon.json)
  • Restart docker-daemon (or your system)
Related Question