[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Network card activation



Oscar Corte wrote:
Raj:

Thanks a lot for your answer. The recommended documentation helped me
to understand many aspects of Linux networking.

Now I use “ifdown” and “ifup” commands to activate my network card
and went to etc/network/interfaces to change the line:

allow-hotplug eth0

for

iface eth0 inet dhcp

This helps because the machine starts up a lot faster and well... no
ip yet but “ifconfig“ reports that eth0 is somehow alive as shown
next:
eth0      Link encap:Ethernet  HWaddr 00:02:44:02:D2:09
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1267 errors:0 dropped:0 overruns:0 frame:0
          TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:76669 (74.8 KiB)  TX bytes:1277 (1.2 KiB)
          Interrupt:3 Base address:0x1460

However. No ip address has been assigned yet and still have to use
ifdown an then ifup esasier than the gui tool) in order to have such
ip address an have access to Internet.

What am I missing in order to have eth0 up and running at start up?

Try running the command 'dhclient' and see whether you are being alloted
an IP address. If you do not get any response, then it probably means
your machine is not able to reach any dhcp servers.

What network are you on? Are you trying to connect to an existing
network, or are you trying to connect to the internet? In the former
case, your network administrator would probably assign an IP address
which you will have to configure manually and your
/etc/network/interfaces file should look something like this:

auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug eth0
iface eth0 inet static
        address 192.168.1.2
        netmask 255.255.255.0
        network 192.168.1.0
        broadcast 192.168.1.255
        gateway 192.168.1.1

HTH,
Raj Kiran



Reply to: