Connect to internet on Ubuntu Server running on qemu virtaul machine

Tags:

Answer: 1

10 hours ago

I am running Ubuntu server in a Qemu VM. The /etc/network/interfaces contents look as follows:

#The loopback network interface
auto lo
iface lo inet loopback

#The primary network interface
auto eth0
iface eth0 inet dhcp

Am I missing something here ?

EDIT I guess it is a problem with connecting the qemu virtual machine to the internet and not specific to ubuntu server, could someone guide me on doing that ?

Added by: Willa Walker DVM

Answer: 2

19 hours ago

eth0 is set to got ip setting from dhcp. If you dont have dhcp on local network server will not got a parameters

To solve this edit /etc/network/interfaces and setup manually ip parameters

 sudo nano /etc/network/interfaces

minimal configuratio is

auto eth0 
iface eth0 inet static
       address xxx.xxx.xxx.xxx 
       netmask xxx.xxx.xxx.xxx 
       gateway xxx.xxx.xxx.xxx 
       dns-nameservers xxx.xxx.xxx.xxx

Replase xxx.xxx.xxx.xxx with real parameters from your local lan. After that do

sudo ifdown eth0

and

sudo ifup eth0
Added by: Ike Hirthe

Popular Search

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z 1 2 3 4 5 6 7 8 9