LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices

Reply
 
Search this Thread
Old 01-29-2005, 10:38 PM   #1
pqueiro
LQ Newbie
 
Registered: Oct 2004
Location: Lisboa, Portugal, EU
Distribution: Debian/Testing
Posts: 6

Rep: Reputation: 0
Problems getting DHCP to work on my laptop


I'm running Debian/Testing on my HP Pavilion laptop and I've recently compiled a new kernel (2.6.8), but after that I noticed DHCPDISCOVER kept failing at boot time. After looking about and messing with all sorts of stuff, I believe I've narrowed it down; apparentely, it's not listening correctly for DHCP offers. Upon boot time it says it's listening and sending on LPF/eth0/<null>, instead of the correct address (which would be, I believe, the router's address, 192.168.1.1). The ethernet card is configured and working, but I have no idea how to set up DHCP decently =/

What's wrong? What can I do?

Thanks for any help you can give me =)
 
Old 01-30-2005, 02:10 AM   #2
adz
Senior Member
 
Registered: Jun 2003
Location: Sydney
Distribution: Debian, FreeBSD
Posts: 1,713

Rep: Reputation: 53
Does it work manually? Try a dhclient eth0 as root.
 
Old 01-30-2005, 05:51 PM   #3
pqueiro
LQ Newbie
 
Registered: Oct 2004
Location: Lisboa, Portugal, EU
Distribution: Debian/Testing
Posts: 6

Original Poster
Rep: Reputation: 0
I tried that, but it didn't work. After that I tried the same command on my working kernel, and I noticed this: on the kernel that doesn't work, it says

Listening on LPF/eth0/<null>

whereas on the kernel that does work, it says

Listening on LPF/eth0/00:02:3f:69:3f:43

that is, my card's MAC address.

I believe that it is clear then, I have to get it to use the correct device... what can I do?

Thanks
 
Old 01-30-2005, 07:29 PM   #4
DavidPhillips
Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,154

Rep: Reputation: 56
try ifconfig -a

look for the device name.

dhcp is a broadcast protocol, make sure it's not firewalled.


Last edited by DavidPhillips; 01-30-2005 at 07:31 PM.
 
Old 01-31-2005, 06:00 PM   #5
pqueiro
LQ Newbie
 
Registered: Oct 2004
Location: Lisboa, Portugal, EU
Distribution: Debian/Testing
Posts: 6

Original Poster
Rep: Reputation: 0
The output of ifconfig -a, on the kernel that "works":

Code:
eth0      Link encap:Ethernet  HWaddr 00:02:3F:69:3F:43
          inet addr:192.168.1.2  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::202:3fff:fe69:3f43/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:264 errors:0 dropped:0 overruns:0 frame:0
          TX packets:302 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:143642 (140.2 KiB)  TX bytes:54841 (53.5 KiB)
          Interrupt:177 Base address:0xa000

eth1      Link encap:UNSPEC  HWaddr 3C-3F-02-00-38-0E-00-3D-00-00-00-00-00-00-00-00
          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)

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:72 errors:0 dropped:0 overruns:0 frame:0
          TX packets:72 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:4740 (4.6 KiB)  TX bytes:4740 (4.6 KiB)

sit0      Link encap:IPv6-in-IPv4
          NOARP  MTU:1480  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:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
eth0 is my LAN card, eth1 my wireless card, lo and sit0 I have no idea >_>

As for the problematic kernel:

Code:
eth0      Link encap:UNSPEC  HWaddr 3C-3F-02-00-38-0E-00-3D-00-00-00-00-00-00-00-00
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:8 dropped:8 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:112 errors:0 dropped:0 overruns:0 frame:0
          TX packets:112 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:7340 (7.1 KiB)  TX bytes:7340 (7.1 KiB)
This opens up a whole new world of possibilities o_O no sit0, to start, and eth0 is suddenly my wireless card. My Ethernet card is nowhere to be seen, which is definitely a problem. ifconfig eth1 up (assuming here that the two cards simply switched places) outputs

Code:
eth1: ERROR while getting interface flags: No such device
meaning the damned thing has no idea my Ethernet card exists.

There's a whole another issue at work here too; if eth0, in the new kernel, is my wireless card, it's not supposed to be working, as I haven't set up ndiswrapper or anything similar (and to the best of my knowledge Debian/Testing doesn't handle Broadcom WLAN cards all by its lonesome <_<); but if my any chance it is working, why isn't it getting dhcp offers from my wireless router (which I'm sure is working, at least with Windows :P)?

Anyway, why doesn't it detect my Ethernet card? How can I get it to?

Thanks for any help

[edit]: Oh, and David, I'm not entirely sure how to check whether DHCP is firewalled or not. How would I do that? Thanks

Last edited by pqueiro; 01-31-2005 at 06:01 PM.
 
Old 01-31-2005, 08:16 PM   #6
forgox
LQ Newbie
 
Registered: Jul 2004
Posts: 27

Rep: Reputation: 15
wright compiler flags?

There might be compiler flags not set properly.

Ensure your ethernet driver is compile in your kernel.
cd /usr/src/linux
make xconfig

If you want to start with clean config, you can try the suggestion below (try it at your own risk);
-you can backup config files from /boot (e.g. /boot/config-* )
-you can rename those config file with temporary names (e.g. add suffix .bak)
-you can rename /usr/src/linux/.config to a new name (e.g. add suffix .bak)
-you can rerun "make xconfig" or equivalent to regenerate /usr/src/linux/.config.

make xconfig usually try to build the /usr/src/linux/.config by looking at existing config file from /boot.The /usr/src/linux/.config contains instruction on how to build the kernel.
-alternatively, you can try leave a good config file in /boot so that "make xconfig" will try to use it as a default config and then you could tweak other parameters that you want.
 
Old 01-31-2005, 09:08 PM   #7
pqueiro
LQ Newbie
 
Registered: Oct 2004
Location: Lisboa, Portugal, EU
Distribution: Debian/Testing
Posts: 6

Original Poster
Rep: Reputation: 0
forgox, I followed this page's instructions on how to compile the kernel seeing as the guy's laptop is so similar to mine and he's using the same distro. Everything went pretty much like he says on the page, except for not finding the 2.6.10 source (stuck with 2.6.8; I suspect it is so because he added unstable entries to his apt-get list). I even tried using his .conf file, but no >_< anyway, my point is that I never saw any compiler flags anywhere, so...

At any rate, that was one error I corrected - the first time I compiled the kernel, I included the wrong drivers for my card, but I think I've got them correctly now. I could check though...
 
Old 01-31-2005, 10:39 PM   #8
DavidPhillips
Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,154

Rep: Reputation: 56
My hp pavilion uses the natsemi module.

/sbin/lspci | grep Eth
00:12.0 Ethernet controller: National Semiconductor Corporation DP83815 (MacPhyter) Ethernet Controller


grep natsemi /etc/modules.conf
alias eth0 natsemi


lsmod |grep natsemi
natsemi 15264 1


/sbin/modinfo natsemi
filename: /lib/modules/2.4.21-273-default/kernel/drivers/net/natsemi.o
description: "National Semiconductor DP8381x series PCI Ethernet driver"
author: "Donald Becker <becker@scyld.com>"
license: "GPL"
parm: max_interrupt_work int, description "DP8381x maximum events handled per interrupt"
parm: mtu int, description "DP8381x MTU (all boards)"
parm: debug int, description "DP8381x default debug level"
parm: rx_copybreak int, description "DP8381x copy breakpoint for copy-only-tiny-frames"
parm: options int array (min = 1, max = 8), description "DP8381x: Bits 0-3: media type, bit 17: full duplex"
parm: full_duplex int array (min = 1, max = 8), description "DP8381x full duplex setting(s) (1)"
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DHCP problems - multiple DHCP servers sat86 Linux - Networking 4 10-02-2005 05:43 AM
laptop dhcp could be the dealbreaker shishimo Linux - Laptop and Netbook 3 06-21-2004 03:45 PM
DHCP server problems -- can't get my box to work as a router KingofBLASH Linux - Networking 1 03-21-2004 06:19 AM
XP Pro Build 2600/sp1 v.1105 DHCP Client to Redhat 8.0 DHCP Server - Problems atomant Linux - Networking 5 06-28-2003 11:24 AM
dhcp server will not connect to laptop after laptop OS upgrade phamnewan Linux - Networking 0 06-21-2003 10:47 AM


All times are GMT -5. The time now is 11:06 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration