I use a virtualbox virtual machine to run Ubuntu from within Windows (yes, I know I am a masochist). Anyway, every time I resume the virtual machine Ubuntu loses connection with the internet and I have to reset the interface. In windows from the command prompt you have to do an
ipconfig /release and an
ipconfig /renew. Similarly in Ubuntu all I had to do was the following:
sudo ifconfig to get a list of all the network interfaces. There you can see the name of the networking interface that you need to reset. In my case I wanted to reset interface “eth3”. So I did:
sudo dhclient -r eth3 to
sudo dhclient eht3 to
That’s it! Got a new IP and I can access the internet!