LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   I can only access the Internet through a virtual machine (https://www.linuxquestions.org/questions/linux-networking-3/i-can-only-access-the-internet-through-a-virtual-machine-4175580796/)

cort3x1n 05-26-2016 08:27 PM

I can only access the Internet through a virtual machine
 
I don't know if this question belongs here or in the virtualization forum so I've placed it here

I have Debian 8 jessie running as the host operating system on my laptop. I then have VMWARE Workstation 12 running multiple different OS's as virtual machines. At the time when this issue started I was working with a windows 7 vm and a Kali 2.0 vm. I had both connected to the internet via NAT.

The problem started with my system starting to lag badly and then locking up to the point where even holding the power button down would not shut it down. I had to unplug the power supply and pull the battery to get it turned off.

Upon booting back in to Debian I was not able to access the internet through the browser or any other means. ifconfig showed a lot of virtual interfaces and bridges that I went through and removed. I removed the virtual networks I had created in vmware and restarted the networking and network-manager multiple times. After all of this, my system looks as though it should be able to access the internet just fine but it cant. Network manager is telling me I'm connected to the ineternet but I can't access any web pages.

Just out of curiosity and because I was at a loss I opened vmware, and created a virtual network (vmnet0) bridged to the physical interface on the host os, it works with both eth0 and wlan0. When I started up one of the vm's and set it to bridged also (not connected to vmnet0) I am able to access the internet just fine one that vm. If I disable vmnet0 in the virtual network editor I lose the connection.

I should also note that before this started I had both vm's set to bridged, but they were not on the same subnet as the host for some reason. ie. the host was on 192.168.1.xxx and the vm's were on 192.168.20.xxx.

I am completely at a loss and I have been unable to find anyone else who has had this issue online.

jefro 05-27-2016 09:34 PM

Hello and welcome to LQ.


I tend to look at the internet as a collection of things.

One is tcp/ip and that should mostly be working since you can use it in the client. The story sort of stops there with any references to clients so you need to be looking at the host only.


Second thing I might look at is the hosts dns entries. Without them you can't resolve names so command line tools like dig and nslookup help there. I'd start there first.

However, when you have a crash or very odd things you may have a system with many odd issues. Usually I try to boot to a live media to check things out.

cort3x1n 05-31-2016 12:56 PM

Thank you for your response. It took a few more days but I managed to find the issue, though I still don't completely understand what happened. A week or two before this started I was working on something else and had set up iptables rules to go along with a VPN. When I finished with that I disabled the firewall and the VPN but I guess I missed something because somehow when I was messing with the VM network and the bridge those iptables rules got turned back on and since they were set up to route all traffic through the VPN which was no longer set up, no internet.I'm not sure why I was able to access the internet through the VM though.

jefro 05-31-2016 02:45 PM

Thanks for the reply. Glad you have it fixed and posted the solution.

Sometimes easy to break stuff on the road to working.


All times are GMT -5. The time now is 07:49 AM.