My host is an out-of-the-box Ubuntu 12.10 simply connected to Wifi.
I'm running the guest headless by starting with vboxmanage.exe using -headless. I'm running VirtualBox v4.1.12 (but this was also happening with 4.1.10). My guest OS is running nothing but iTunes. Quite a large iTunes Library, but it isn't very active. VBoxHeadless.exe has stopped working. By AdamUK » 10. Apr 2012, 09:09.
I installed VirtualBox, and then a few Linux and Windows 7 Pro guests on it, all with default VirtualBox options (NAT).
I reboot them every day.
Yesterday all had network access.
PROBLEM: Today all the Windows guests says 'No Internet access'.
Linux guests still have network.
As an experiment, I created a new guest VM, installed Windows inside. Result: no network.
All Windows and Linux guests are out-of-the-box, I did no network tweaking whatsoever. Below is their VirtualBox-side network configuration just in case:
(2 years later: exact same problem happened, a VM that was working yesterday... same solution)
2 Answers
As John Siu tipped me, there is probably something wrong with the DNS server in my network.
The solution was to change the DNS from Obtain DNS server address automatically
to Use the following DNS server addresses
, and entering Google's DNS service addresses, as seen in this screenshot:
Did you try to ping from inside any windows guest?
No Internet access
is NOT the same as losing network connection. It properly still have LAN connection, but Window think it cannot reach the internet.
When Windows start it make some internet connection(not sure what), if failed it will show that notification sign. It usually go away once you start browsing the web or make some internet traffic. If you have internet connection, the sign may go away by itself in a few minutes.
John SiuJohn SiuNot the answer you're looking for? Browse other questions tagged windows-7networkingvirtualboxinternet-connectionnat or ask your own question.
All of the sudden gksu stopped working for me:
The same happens with gparted-pkexec
:
What could possibly be causing this?
I am not running this through SSH or VNC. This is localhost in a normal terminal window.
Mark Paskal3 Answers
If running Ubuntu 17.10 or newer, this issue can arise when an application has not been updated with full support for Wayland. As a workaround until the application is updated, you can run
which will allow the root
user to display applications on your desktop. Also see this Q&A for other possible workarounds: Why don't gksu/gksudo or launching a graphical application with sudo work with Wayland?
Try running xhost +localhost
in your terminal, and then running the command again. This lets all users on your system (i.e. root) open windows on your screen. Make sure to use +localhost and not simply +, as it's more secure to allow connections from only localhost than from anywhere.
To make this permanent, edit the ~/.xinitrc
file like this:
Run gedit ~/.xinitrc
Edit the file to look like this (it should be empty at the start):
Now save the file, log out and log in. Now everything should run just fine with sudo.
I can't reproduce your problem on 14.04, but this has worked for me in the past when sudo / gksu threw this error.
Sources:
wjandreaExecute the following in your terminal:
Add the following line at the end.