Ubuntu: Can't connect to host's internet connection using NAT

user994165

I installed Lubuntu on Virtualbox. I'm using Windows 7 x64. My VM is 32 bit version. The internet works using Bridged Adapter, but I'm trying to use NAT so I can use a VPN. In Network and Sharing Center in Windows, I see connection "VirtualBox Host-Only Connection" and it says "No Internet Access". In properties, "VirtualBox Bridged Networking Driver" is checked. The following is the output of ifconfig:

dev@dev-VirtualBox:~$ ifconfig
eth0      Link encap:Ethernet  HWaddr 08:00:27:f3:48:24  
          inet addr:10.0.2.15  Bcast:10.0.2.255  Mask:255.255.255.0
          inet6 addr: fe80::a00:27ff:fef3:4824/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:379 errors:0 dropped:0 overruns:0 frame:0
          TX packets:421 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:32105 (32.1 KB)  TX bytes:34987 (34.9 KB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:856 errors:0 dropped:0 overruns:0 frame:0
          TX packets:856 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:56432 (56.4 KB)  TX bytes:56432 (56.4 KB)

Routing Table:

dev@dev-VirtualBox:~$ route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
default         10.0.2.2        0.0.0.0         UG    0      0        0 eth0
10.0.2.0        *               255.255.255.0   U     1      0        0 eth0
dev@dev-VirtualBox:~$ 

Connection Editor: General: Automatically Connect to this network when it isn't available, All users may connect ot this network Ethernet: MTU automatic IPV4: Automatic (DHCP), Require ipv4 addressing for this connection to complete IPV6: Ignore

dev@dev-VirtualBox:~$ cat /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
user994165

It turns out that NetworkManager was not updating /etc/resolv.conf with the nameservers.

Commenting out dns=dnsmasq in /etc/NetworkManager/NetworkManager.conf worked after rebooting.

From here (the first solution didn't work for me) https://askubuntu.com/questions/137037/networkmanager-not-populating-resolv-conf

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Can't connect to web-server on local host behind NAT

From Dev

Cannot Connect CentOS VM to Internet (NAT Connection)

From Dev

Can't connect to internet on minimal Ubuntu

From Dev

Ubuntu Server 16.04.3 Can't Connect to Internet

From Dev

VirtualBox: Ubuntu guest can't connect to Internet

From Dev

I can't connect to the internet using ethernet

From Dev

I can't connect to the internet using ethernet

From Dev

can't connect to local internet using wire

From Dev

Can't connect to internet in chroot using Cubic

From Dev

Unable to connect to Internet on a VM (NAT & Host only networks enabled)

From Dev

Can't connect to server using Connection String

From Dev

Ubuntu 16.10 Can't connect to internet (Cable nor wireless)

From Dev

Can't connect to the internet with static IP Ubuntu Server 18.04

From Dev

Can Connect to Internet Over VPN Using Debian VM But Not Ubuntu

From Dev

Is it my computer's fault that I can't connect to the internet?

From Dev

I can connect to my wifi, but I can't connect to internet in post-installation of Ubuntu 16.04

From Dev

VMWare Can't Connect To Internet

From Dev

Can't connect to Cassandra remote host using cqlsh

From Dev

Connection refused / couldn't connect to host

From Dev

Cannot connect to VirtualBox VM from Kubuntu Host using NAT

From Dev

Can't Access Apache on VirtualBox VM (using NAT + Host-only)

From Dev

Can't Access Apache on VirtualBox VM (using NAT + Host-only)

From Dev

Can't connect via SSH from host Mac OS to guest Ubuntu: Host is down

From Dev

Can't connect to a wired connection

From Dev

Can't connect to a wired connection

From Dev

Ubuntu Server can access the internet, but I can't connect to it on the local network

From Dev

Ubuntu Server can access the internet, but I can't connect to it on the local network

From Dev

How can I connect to the internet in Ubuntu server?

From Dev

Can not connect to internet in VirtualBox VM - Ubuntu

Related Related

  1. 1

    Can't connect to web-server on local host behind NAT

  2. 2

    Cannot Connect CentOS VM to Internet (NAT Connection)

  3. 3

    Can't connect to internet on minimal Ubuntu

  4. 4

    Ubuntu Server 16.04.3 Can't Connect to Internet

  5. 5

    VirtualBox: Ubuntu guest can't connect to Internet

  6. 6

    I can't connect to the internet using ethernet

  7. 7

    I can't connect to the internet using ethernet

  8. 8

    can't connect to local internet using wire

  9. 9

    Can't connect to internet in chroot using Cubic

  10. 10

    Unable to connect to Internet on a VM (NAT & Host only networks enabled)

  11. 11

    Can't connect to server using Connection String

  12. 12

    Ubuntu 16.10 Can't connect to internet (Cable nor wireless)

  13. 13

    Can't connect to the internet with static IP Ubuntu Server 18.04

  14. 14

    Can Connect to Internet Over VPN Using Debian VM But Not Ubuntu

  15. 15

    Is it my computer's fault that I can't connect to the internet?

  16. 16

    I can connect to my wifi, but I can't connect to internet in post-installation of Ubuntu 16.04

  17. 17

    VMWare Can't Connect To Internet

  18. 18

    Can't connect to Cassandra remote host using cqlsh

  19. 19

    Connection refused / couldn't connect to host

  20. 20

    Cannot connect to VirtualBox VM from Kubuntu Host using NAT

  21. 21

    Can't Access Apache on VirtualBox VM (using NAT + Host-only)

  22. 22

    Can't Access Apache on VirtualBox VM (using NAT + Host-only)

  23. 23

    Can't connect via SSH from host Mac OS to guest Ubuntu: Host is down

  24. 24

    Can't connect to a wired connection

  25. 25

    Can't connect to a wired connection

  26. 26

    Ubuntu Server can access the internet, but I can't connect to it on the local network

  27. 27

    Ubuntu Server can access the internet, but I can't connect to it on the local network

  28. 28

    How can I connect to the internet in Ubuntu server?

  29. 29

    Can not connect to internet in VirtualBox VM - Ubuntu

HotTag

Archive