You are not logged in.

#1 2009-03-04 15:36:52

Joshmotron
Member
Registered: 2009-03-04
Posts: 21

DHCPCD Timeouts

Short back story, left FreeBSD the other night for several reasons that have been bugging me about it and wanted to go back to Linux, but not Ubuntu, saw lots of good things about this one, most specifically the seemingly much more knowledgeable community.

Anyhows, it seems that everytime I install a non-Windows OS I get one friggin annoying problem that makes the first week or so as irritating as possible... this time it seems to be that I can't get an IP address through DHCP.  It worked no problem during the install and afterwards with FreeBSD (asks me about having some dc0-like device, searched, brought up all the details), but so far I've gotten it to run twice (once during the install, once after, but it was very random).  For some reason, I've got two interfaces on my motherboard and one pci card one too, I generally prefer the PCI one for no real reason whatsoever (it's what I used when using BSD.)   I'm not connected through any router or hub, just straight to the modem and out of my apartment goes the signal. 

Anytime I run 'dhcpcd eth#' it says broadcasting for signal then timeouts afters the default 30 seconds, no other errors I know of, nothing more.  Just broadcasts and dies.  (I say eth# because I've tried it in all three connections I have and run it everywhichway imaginable.)  Sometimes it comes up that it's looking for a carrier depending on where I plug it in, THEN broadcasts for lease, THEN timeouts.  It's a very boring process. sad  I thought maybe I'd give it more time (even though BSD caught it in less than 5 seconds during install) but doing something like 'dhcpcd -t 500 eth0' still timesout at 30 seconds.

I'd post much more specific errors, but it's my only computer, my only OS (dual booting to windows is for pansies), so I have to post at Work until I bring my lappy home tonight.  Mostly just gathering info right now.

(Also, I have my old settings from the FreeBSD login: ipv4 (173.88.203.86), dns (65.?.?.10), gateway (173.88.203.1), host (joshcomp), domain (neo.rr.com), I think one more, don't have them with me, doing this by memory, but I know the only option it didn't give me that I run into all the time here in Arch is broadcast, but I have no idea how to use these or if they'd work here.)

Last edited by Joshmotron (2009-03-04 15:41:35)

Offline

#2 2009-03-04 18:52:57

ckristi
Member
From: Bucharest, Romania
Registered: 2006-11-21
Posts: 225

Re: DHCPCD Timeouts

Can you, please, show us what your /etc/rc.conf contains. Furthermore, please tell us what's the NIC that's wired to your local network (eth0, 1 or 2).


In love I believe and in Linux I trust

Offline

#3 2009-03-05 05:30:29

Joshmotron
Member
Registered: 2009-03-04
Posts: 21

Re: DHCPCD Timeouts

My rc.conf is, without comments or anything:

HOSTNAME="myhost"
eth2="dhcp"
INTERFACES=(eth2)
NETWORKS=(myhost)
gateway="default gw 192.168.0.1"
ROUTES=(!gateway)
DAEMONS=(syslog-ng network netfs crond)

resolv.conf
search neo.rr.com
nameserver 65.24.7.10
nameserver 65.24.7.11

# For some reason this was NOT written from my install stuff to my hard drive, no idea why.

Also, I'm now exactly sure how to find out which particular NIC is hooked up to what interface.

Also, it turns out that I got it to hook up again on my computer, but I have a feeling if I reboot it'll be the same process again.
What happened:
  Went back to install disc, hooked up my ethernet cable to the bottom of my two built-in mobo ones after DHCP timed out with my PCI card one.  After doing this, I looked up for eth2 (just a guess, these things giveno info I'm aware of to tell you exactly which is which.)  Found all the info right away.  Installed.  When it finished with packages and asked if I wanted to use install settings in my resolv.conf and rc.conf, I said yeah.  But when I looked at them, nothing had been written in.  After my install, I copied all the info down from resolv.conf (the install HAD written something there, but just for the cd) and gave me an eth2="dhcp" INTERFACES=(eth0) in my rc.d, which didn't seem right, but at least I had resolv.conf settings -- turns out I can't figure out how to work with just DNS nameservers.

When I installed, of course it timed out, I tried doing things statically but I don't know how to set static in rc.conf, and I had installed netcfg this time from the install and that didn't do much of anything.  I made some pretty profiles? sad

Anyway, I tried doing a 'dhcpcd eth2' after an ifconfig eth2 up (and making sure the eth0 and eth1 were down) and it timed out, of course...  So I switched the cable from the bottom to the top mobo built in slot and just did the exact same thing, BING, worked.  Leasing for 3600 seconds.  Although this'll probably fail to work when I boot up again.  Also, when I dmesg | grep eth2, there are like 8 lines saying eth2: no link during initialization, then all the sudden, eth2: link up.
My ifconfig shows inet addr: 71.74.226.163 but route shows local address as 173.88.215.7.  Thoroughly confused. I wish I knew more about the workings of networks/internets.

Offline

#4 2009-03-05 15:10:58

slot
Member
Registered: 2008-09-08
Posts: 65

Re: DHCPCD Timeouts

I too have dhcpcd timeouts on two machines on my companys network.
The one is my laptop - it worked without a flaw until I dualbooted xp - after that dhcpcd don't give an IP for some days.
dhclient works immediately. I can see in the dhcp servers log that it receives the request and offers the usual IP as it should.
At my home network there is no problem dualbooting and getting address by dhcpcd
From rc.conf:

eth0="dhcp"
INTERFACES=(eth0)

The other is a server I am setting up, it worked alright until I configured a bridge setup, which did not get an IP. Again I could see in dhcp servers log that it was requesting and server is offering it allright, but somehow the client don't receive.
Now switching back to non-bridged setup eth0 cannot get IP with dhcpd - same story.

Offline

#5 2009-03-06 05:52:20

ckristi
Member
From: Bucharest, Romania
Registered: 2006-11-21
Posts: 225

Re: DHCPCD Timeouts

Your problem still seems weird, but... if you want to use DHCP you will have to comment out gateway and ROUTES lines in the rc.conf. I don't know ATM if this is documented somewhere, but I know this is my configuration. Well, also I don't have 3 NICs on any of my computer. :-)


In love I believe and in Linux I trust

Offline

#6 2009-03-06 11:28:16

Joshmotron
Member
Registered: 2009-03-04
Posts: 21

Re: DHCPCD Timeouts

Yeah, my most annoying thing probably is my 3 NIC cards, can't figure out which is which by the eth number.  Somehow it seems sorted out... for now.  My internet was up constantly yesterday and the night before that, even made it through a reboot kinda quicklyish.  Hell, it feels quicker than ever.  *grumble

Offline

Board footer

Powered by FluxBB