Configuring 2nd network interface (command line)

Maxime Alarie malarie at processia.com
Wed Jun 16 19:08:55 UTC 2010


Good day,

 

I have 2 network cards on my Ubuntu 9.1 server.  The 1st one is
configured  on my Domain, DHCP enabled (with reservation on the dhcp
server).

The 2nd one, is there, when I ifconfig  but its not displayed in
/etc/network.interface, im looking to configure eth0.

 

 

Output of  /etc/interface

root at Washington:/etc/network# cat interfaces

# This file describes the network interfaces available on your system

# and how to activate them. For more information, see interfaces(5).

 

# The loopback network interface

auto lo

iface lo inet loopback

 

# The primary network interface

auto eth1

iface eth1 inet dhcp

 

 

 

Ouput of ifconfig:

eth0      Link encap:Ethernet  HWaddr $MACADDR

          UP BROADCAST MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

          Memory:da020000-da040000

 

eth1      Link encap:Ethernet  HWaddr $MACADDR

          inet addr:XXX.XXX.XXX.XXX  Bcast:XXX.XXX.XXX.XXX
Mask:255.XXX.XXX.XXX

          inet6 addr: $IPV6  Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:3009889 errors:0 dropped:0 overruns:0 frame:0

          TX packets:365228 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:100

          RX bytes:1039941534 (1.0 GB)  TX bytes:75767637 (75.7 MB)

          Memory:da060000-da080000

 

 

 

I would like to give a testing ip address to ETH0, Do I have to insert
anything in interface?  Like this example?

 

# The primary network interface

auto eth0
iface eth0 inet static
address 192.168.3.90
gateway 192.168.3.1
netmask 255.255.255.0
network 192.168.3.0
broadcast 192.168.3.255

 

Thanks.

 

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20100616/48df7dbe/attachment.html>


More information about the ubuntu-users mailing list