Page 1 of 1

VirtualBox - Can't connect to internet NAT adaptor

Posted: 29. Aug 2018, 15:11
by inessa
Good Evening,

I'm having an issue with VirtualBox networking.

I am running a client-server architecture, whereby both machines have one adaptor as NAT, and another as internal network to communicate with each other. When operating virtualbox at uni (connected to wi-fi), the machines both are able to ping google as well as each other, so the networking is fine.

For some reason, over the last few days, coming back to my room and connecting to Wi-fi, it doesn't seem to work. I tried having just one adaptor on each machine, and when I do that seems to work fine (there is internet access when I only have one adaptor connected to NAT.) However switching on both adaptors, the machines can ping each other, but do not get internet access. I am using an Ubuntu Machine as the client, and a Debian Machine as the server.

Any help would be greatly appreciated. Cheers

Re: VirtualBox - Can't connect to internet NAT adaptor

Posted: 30. Aug 2018, 10:31
by socratis
You didn't mention host, guests or VirtualBox versions, builds, revisions. You kind of have to, so that we know what we're talking about. And mind you: Debian/Ubuntu/other is *not* a version, it's a "family of OSes". Details might be essential. There's a huge difference between Ubuntu 8.04 and 18.04. And it's not just that "1" digit... ;)

We're also going to need the network configuration of the guests. And the host. Outputs of "ifconfig -a" or "nmcli dev show" for example. From both situations; work/home. And the diagnostics that you've attempted. Ping what from what? With numbers...

Re: VirtualBox - Can't connect to internet NAT adaptor

Posted: 20. Sep 2018, 17:09
by naus911
You have check the your ip configuration in you Guest VM.
I had the same problem and did put the ip address manual.
in your NAT configuration
you must have the gateway with 10.0.2.2 and the DNS too the same ip 10.0.2.2.

good look!