Help - Search - Members - Calendar
Full Version: dhcp client problems
MandrivaUsers.org > Advanced Topics > Networking
nobody
Lo,

I have some problems connecting to the internet with mandrake 10(2.6.2-3mdksmp).I have an onboard lan(eth0) wich i like to use for connection with my laptop and realtek networkcard(eth1) witch is connected to my cable modem.

I have a cable connection with brutele in brussels(belgium) and I tried drakconnect with dhcp-client / dhcpxd / dhcpd. .

He seems to find the dhcpserver because when I run the drak wizard for a new connection I get DNS server1 212.68.193.217 and DNS server2 212.68.193.216. and search domain brutele.be.

When i do monitor connections i click connect i see stuff being send and received and the lights on my modem go off and on (send /receive).

So I tried manualy running dhcp-client, then I see some discoveries, requests and offers, its like they miss eachother:

dhclient:
---------

Internet Software Consortium DHCP Client V3.0.1rc13
Copyright 1995-2002 Internet Software Consortium.
All rights reserved.
For info, please visit http://www.isc.org/products/DHCP

sit0: unknown hardware address type 776
/sbin/dhclient-script: configuration for sit0 not found.
/sbin/dhclient-script: configuration for lo not found.
sit0: unknown hardware address type 776
Listening on LPF/eth0/00:0c:6e:64:14:ef
Sending on LPF/eth0/00:0c:6e:64:14:ef
Listening on LPF/sit0/
Sending on LPF/sit0/
Listening on LPF/lo/
Sending on LPF/lo/
Listening on LPF/eth1/00:c0:49:d5:a2:dd
Sending on LPF/eth1/00:c0:49:d5:a2:dd
Sending on Socket/fallback
DHCPDISCOVER on sit0 to 255.255.255.255 port 67 interval 3
send_packet: Network is down
DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 5
receive_packet failed on sit0: Network is down
DHCPOFFER from 213.189.176.1
DHCPREQUEST on eth1 to 255.255.255.255 port 67
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
DHCPDISCOVER on lo to 255.255.255.255 port 67 interval 4
DHCPDISCOVER on sit0 to 255.255.255.255 port 67 interval 8
send_packet: Network is down

.....and so on....



I had same problem some time ago with debian (not solved), but dhcpd worked with gentoo... and knoppix is running fine too (running it as we speak).

ifup eth1 ==> Determining IP information for eth1... done.
ifstatus ===> lo: not supported
sit0: not supported
eth0: not supported
eth1: link beat detected

INFO:
=====

System:
---------

P4 / ASUS P4P800 deluxe

eth0:
-----
Vendor: ?3Com Corporation

Bus: ?PCI

Bus identification: ?10b7:1700:1043:80eb

Location on the bus: ?2:5:0

Description: ?3C940 10/100/1000 LAN

Module: ?sk98lin

Media class: ?NETWORK_ETHERNET


eth1:
-----
Vendor: ?Realtek

Bus: ?PCI

Bus identification: ?10ec:8139:16ec:ff

Location on the bus: ?2:b:0

Description: ?RTL-8139

Module: ?8139too

Media class: ?NETWORK_ETHERNET



ifconfig:
--------

eth0 Link encap:Ethernet HWaddr 00:0C:6E:64:14:EF
inet6 addr: fe80::200:ff:fe00:0/64 Scope:Link
UP BROADCAST RUNNING 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 cool.gif TX bytes:0 (0.0 cool.gif
Interrupt:22 Memory:feaf8000-0

eth1 Link encap:Ethernet HWaddr 00:C0:49:D5:A2:DD
inet addr:213.189.179.97 Bcast:213.189.179.255 Mask:255.255.252.0
inet6 addr: fe80::2c0:49ff:fed5:a2dd/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:14 errors:0 dropped:0 overruns:0 frame:0
TX packets:40 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:1466 (1.4 Kb) TX bytes:4645 (4.5 Kb)
Interrupt:23 Base address:0xf400

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:270 errors:0 dropped:0 overruns:0 frame:0
TX packets:270 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:22344 (21.8 Kb) TX bytes:22344 (21.8 Kb)

ifcfg-eth0:
-----------
DEVICE=eth0
BOOTPROTO=dhcp
ONBOOT=yes


ifcfg-eth1:
-----------

DEVICE=eth1
BOOTPROTO=dhcp
ONBOOT=yes
MII_NOT_SUPPORTED=no
NEEDHOSTNAME=yes


Can anyone help?

Thx in advance


Edit: moved from Installing Mandrake by spinynorman
Gowator
I think its becuase of the order they are being set.

knoppix works because you run the pppoe-conf script last and it sets default route to the cable connection on eth1

what is your default route (well what does
CODE
route
say)
nobody
I just tried switchign cable to my eth0 but no reaction, also no lamp swithches on when i plug in ...

route output :

QUOTE
Kernel IP routing table
Destination    Gateway        Genmask        Flags Metric Ref    Use Iface
192.168.0.0    *              255.255.255.0  U    0      0        0 eth0
213.189.176.0  *              255.255.252.0  U    0      0        0 eth1
127.0.0.0      *              255.0.0.0      U    0      0        0 lo
default        *              0.0.0.0        U    0      0        0 eth0
nobody
hmm code seems better for display (i can't edit my posts here?)

CODE
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.0.0     *               255.255.255.0   U     0      0        0 eth0
213.189.176.0   *               255.255.252.0   U     0      0        0 eth1
127.0.0.0       *               255.0.0.0       U     0      0        0 lo
default         *               0.0.0.0         U     0      0        0 eth0
Gowator
yep so a temp fix is
route del default
route add default gw 213.189.176.0
nobody
QUOTE (Gowator @ May 11 2004, 11:34 AM)
yep so a temp fix is
route del default
route add default gw 213.189.176.0

:( no succes :(

CODE
# route del default
# route add default gw 213.189.176.0
SIOCADDRT: Network is unreachable
# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
213.189.176.0   *               255.255.252.0   U     0      0        0 eth1
127.0.0.0  
nobody
knoppix output

CODE
# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
213.189.176.0   *               255.255.252.0   U     0      0        0 eth0
default         213.189.176.1.b 0.0.0.0  
Gowator
sorry
repeat (delete the default again with)
route del default
then
route add default 213.189.176.1
nobody
QUOTE (Gowator @ May 11 2004, 03:20 PM)
sorry
repeat (delete the default again with)
route del default
then
route add default 213.189.176.1

THANK YOU! It's working...

Is this setting being saved now or do i have to add to an init script or something else?
Sarissi
Before you go moving the Cable connection to the NIC: Turn OFF the Cable Modem and leave it off for at least 5 minutes. This will Clear the MAC in the cable modem.

I learned this one the hard way. Called the cable ISP and asked.
nobody
QUOTE (Sarissi @ May 11 2004, 03:39 PM)
Before you go moving the Cable connection to the NIC: Turn OFF the Cable Modem and leave it off for at least 5 minutes. This will Clear the MAC in the cable modem.

I learned this one the hard way. Called the cable ISP and asked.

i know i had to do that a few times for gettin knoppix online...
nobody
but its easier to relaese ip with:

linux:
CODE
ifdown <device>
for ex.
CODE
ifdown eth0

windows:
CODE
ipconfig /release
Gowator
nope its still cached in the cable modem....

you can either swap them over ..... OR
you need to edit /etc/init.d/network points to the /etc/sysconfig/networking

and change the order of eth0 and eth1 i.e its presently doing lo0, etrh0, eth1 and you want lo0, eth1, eth0 so that eth0 gets the last dhcp and then automatically over writes the resolv.conf and routes....

Or you can make a script to just redo it after.....

(not neat but works)
nobody
what if change /etc/sysconfig/network

now its:
CODE
HOSTNAME=chief
NETWORKING=yes
GATEWAYDEV=eth0


and would like to try and change it to:
CODE
HOSTNAME=chief
NETWORKING=yes
GATEWAYDEV=eth1
nobody
QUOTE (nobody @ May 11 2004, 04:51 PM)
what if change /etc/sysconfig/network

now its:
CODE
HOSTNAME=chief
NETWORKING=yes
GATEWAYDEV=eth0


and would like to try and change it to:
CODE
HOSTNAME=chief
NETWORKING=yes
GATEWAYDEV=eth1

K that didn't work but eth0 and eth1 or not mentioned in /etc/init.d/network
nobody
Ok this is funny i remove cfg-eth0 from network-scipts in /etc/sysconfig and when i reboot it doesn't work but when go to configuration tool and then to internet stuff without changing anything it works..

but when i don't go there it doens't work ??? wall.gif strange things going on...


[edit]
woohoo we can edit our posts now smile.gif

does anyone know how the system configuration tool works? what files it makes?

when i click system configuration tool
then I give my root passwoord
internet configuration
make new connection
i select cable
the i select eth1

en without doing anything else after the clicking of the box after eth1, my internet works, so i suppose it creates some file at that point?
[/edit]
Gowator
hmmm ... I honestly think you might wanna abandon the draketools for this.
In my experience they work very well or not at all and the not at all tends to be what yuour doing. I have to admit not trying this in the GUI for a long while.


problem is I might be busy ....

however what you need to get is pppoe-conf.

(Im assuming your comfortable with urpmi and CLI )
I usually use webmin and create the interfaces ....
In your case Id delete them all then restart....
add eth0 and eth1 etc. and set them up .... it takes longer than the wizard does when it works but is faster than trying to sort out the mess when it doesnt

Also ...another option used to be linuxconf. This is now removed from Mandrake becuase its incompatible with the wizards .... BUT its much more flexible....


(p.s. your gnome prob might be NW related)
nobody
QUOTE (Gowator @ May 12 2004, 08:36 AM)
hmmm ... I honestly think you might wanna abandon the draketools for this. 
In my experience they work very well or not at all and the not at all tends to be what yuour doing.  I have to admit not trying this in the GUI for a long while. 


problem is I might be busy ....

however what you need to get is pppoe-conf. 

(Im assuming your comfortable with urpmi and CLI )
I usually use webmin and create the interfaces .... 
In your case Id delete them all then restart.... 
add eth0 and eth1 etc. and set them up .... it takes longer than the wizard does when it works but is faster than trying to sort out the mess when it doesnt

Also ...another option used to be linuxconf.  This is now removed from Mandrake becuase its incompatible with the wizards .... BUT its much more flexible.... 


(p.s. your gnome prob might be NW related)

the first time i ran linuxconf it worked fine and i changed the settings, after that it reported an error it could not start dhcpd ...

so i tried rebooting since i allready had ran the drak wizzard for internet

but linuxconf is freezing on me now when i try "hostname and ip network devices"



btw i have webmin installed but i doesn't accept my normal login and passwd? do i have to set one first somewhere?


it doesn't seem to end...


*update*

ok had to use root login, stupid me smile.gif
nobody
hmmm webmin seems a good tool but still no luck

excerpts boot.log:
CODE
May 12 13:44:56 chief network: Setting network parameters:  succeeded
May 12 13:44:57 chief network: Bringing up loopback interface:  succeeded
May 12 13:44:57 chief network: Bringing up interface eth1:  failed

CODE
May 12 13:45:09 chief dhcpd: dhcpd startup failed
Gowator
erm Im at work so cant check plus internet has been out half the morning...

but are you sure thats the client your having probs with ....

eth1 needs to be connected to something that will provide the IP address and other DHCP stuff .... what is it connected to again ?
nobody
QUOTE (Gowator @ May 12 2004, 11:53 AM)
erm Im at work so cant check plus internet has been out half the morning...

but are you sure thats the client your having probs with ....

eth1 needs to be connected to something that will provide the IP address and other DHCP stuff .... what is it connected to again ?

to my cable modem (butele brussels belgium)
Gowator
what I mean is isn't dhcpd the SERVER not the client.

when you start the interface then it just runs a one off search for a IP and stuff ....

I think you might be mixing the two up..... hence confusing yourself.

Sometimes cable modems dont give out a DHCP becuase they use PPPOE directly.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.