So I'm on a work laptop whose internet connection goes through the company proxy server by default. When I disconnect from the proxy and access the internet directly, my laptop accesses the internet without a problem, but my Ubuntu VM (running in VirtualBox, with Windows 10 as the host OS) has no internet access and is unable to resolve the IP address of www.google.com .
I'm guessing I was behind the proxy when I set up the VM, but I just want to know how to fix this (without having to make a new VM). I tried restarting the VM with "Bridged" networking instead of "NAT" networking, but that did no good.
Thanks in advance for the help.
Found a workaround (see below). Only downside is that DNS resolution becomes slow when I resume using the proxy, but that is fixed by reverting the change.
sudo apt-get install && sudo apt-get install resolvconf sudo vim /etc/resolvconf/resolv.conf.d/head Add the following lines: nameserver 8.8.8.8 nameserver 8.8.4.4 sudo resolvconf -u sudo service resolvconf restart
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.