I am using Ubuntu 14.04 with MATE, and my problem is that when I use a local Ethernet cable to access local network via a router (which is not connected to Internet), and at the same time Wireless (or Mobile Broadband) to access the internet - I cannot access the Internet, because apparently Ubuntu tries to first do Internet communication via the wired Ethernet cable, and it locks in there (as the wired Ethernet is, as I mentioned, not connected to Internet).

So, I've seen Set specific interface for internet access , where the answer is:

These routes are automatically created by NetworkManager. Try checking Edit ▸ IPv4 Settings ▸ Routes ▸ Use this connection only for resources on its network on the two LAN connections to prevent them from becoming the default gateway.

Ok, so I go to Network Connections / Edit, Edit the "Auto Ethernet connection", and enable "Use this connection only..." and Save. Then ifconfig reports to me (say) for eth0, and so I test first pinging other local PCs:

$ ping
PING ( 56(84) bytes of data.
64 bytes from icmp_seq=1 ttl=64 time=0.554 ms
64 bytes from icmp_seq=2 ttl=64 time=0.638 ms

Well, so far so good; so I enable my Broadband - and at this point, I have this route:

$ ip route
default via dev ppp0  proto static dev ppp0  proto kernel  scope link  src dev eth0  proto kernel  scope link  src  metric 1 

... and let's see if pinging something online works:

$ ping google.com
PING google.com ( 56(84) bytes of data.
64 bytes from icmp_seq=1 ttl=224 time=1155 ms
64 bytes from icmp_seq=2 ttl=224 time=436 ms

Oh nice, it works... or does it? Let's try retrieving something online:

$ wget http://google.com -O -
--2016-04-27 10:50:09--  http://google.com/
Resolving google.com (google.com)...
Connecting to google.com (google.com)||:80... ^C

Basically it hangs there for more than a minute, and I have to hit Ctrl-C to break/interrupt it.

And now, from Network Manager, I disconnect "Auto Ethernet", and when I try downloading the same resource again:

$ wget http://google.com -O -
--2016-04-27 10:51:12--  http://google.com/
Resolving google.com (google.com)...,,, ...
Connecting to google.com (google.com)||:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: http://www.google.dk/?gws_rd=cr&ei=gX0gV4rVAYe6sQHrzbnICg [following]
--2016-04-27 10:51:13--  http://www.google.dk/?gws_rd=cr&ei=gX0gV4rVAYe6sQHrzbnICg
Resolving www.google.dk (www.google.dk)..., 2a00:1450:4010:c08::5e
Connecting to www.google.dk (www.google.dk)||:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: ‘STDOUT’

    [<=>                                    ] 0           --.-K/s              <!doctype html><html itemscope="" itemtype="http://schema.org/WebPage" ...

Well... now it works - but of course, NOT with the both connections active, but only with the Ethernet disconnected.

So let me repeat the question: how can I have two network connections active at the same time in Network Manager, such that the wired Ethernet connection is used to communicate only to the local network of the router it is connected to - and the wireless/broadband connection is used to access the Internet?

  • 1
    Investigate on route. It shows the routing table of the PC and allows you to change it. – migrc Apr 27 '16 at 9:53
  • Thanks @migrc - I've already used ip route in the OP, had forgotten route is a different command; but as I posted in the answer below, seems the problem was a NetworkManager setting. – sdbbs Apr 27 '16 at 9:56

OK, I think I got it - my Auto Ethernet connection was set to Method "Automatic (DHCP)", and I noticed more-less by accident there is another option "Automatic (DHCP) addresses only", so I tried setting that:


... and finally, I can have both local Ethernet and broadband connections active - and I can access both local network addresses and Internet.

Hope that was it with this problem...

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.