p-chan
January 20th, 2005, 20:11
Sorry guys, haven't been around much recently.

I recently rebuilt my firewall box with OpenBSD 3.6. I didn't want to bother with an upgrade and the configuration is basic enough that I just wiped it clean and reinstalled. Everything went smoothly after I found a working cd and floppy drive (hardware is getting old...) untill I brough it up after the first reboot. Both nics were reporting no link. I honestly forget what the cards are, I think they are linksys etherfast cards, but the os sees them as dc0 and dc1 respectivly. When netstart runs it seems to read the hostname files properly. It assigns the proper address on dc0 and tries to get a dhcp address for dc1. Dhclient will give up and say there is no link, then pf will complain because the cards arn't configured. Once I do an ifconfig up on both cards everything is fine but I have to do this manually after every boot. Then I have to manually start dhclient on dc1 and load the pf.conf file. Its kind of a pain and I would like to take care of it if possible. I've had these same cards in the machine since 2.8 and just went up from 3.4. I've never had this problem before. There are link lights on the switch and cable modem up untill it probes the cards at boot if that helps any.

thanks

andy

cod3fr3ak
January 21st, 2005, 00:11
Hmm.. I had a problem similar to this. My cards were 3com though and they kept timing out on boot up. I switched cards (cause I have a thousand nics laying around my place) and everything is cool. The one thing that i did notice was that the cards read the dc driver as well....

p-chan
January 21st, 2005, 14:23
I managed to hack my way around it after a bit of reading.

Simple solution, have the hostname.if file run ifconfig for me.

This worked fine on the internal nic:
sir_phobos# cat /etc/hostname.dc0
!echo bringing \$if up
!ifconfig \$if up
inet 192.168.0.1 255.255.255.0

I had a little more trouble with the external interface. It takes the machine a second to actually bring up the interface after it gets the ifconfig up command and it doesn't take it quite as long to start the dchp client. So dhcp would still time out. I put a sleep command in the hostname.dc1 file before the dhcp line thinking that would solve the problem. Unfortunately it didn't. I would get a link light on the cable modem but it would still say no link when dhclient ran.

sir_phobos# cat /etc/hostname.dc1
!echo bringing \$if up
!ifconfig \$if up
!sleep 5
dhcp

I tried extending the sleep up to 60s and still the same problem.
Finally I tried replacing the dhcp with a direct call to dhclient, which worked perfectly. Why, I don't know, he's on third, and I don't give a darn.

sir_phobos# cat /etc/hostname.dc1
!echo bringing \$if up
!ifconfig \$if up
!sleep 5
!dhclient \$if

cod3fr3ak
January 26th, 2005, 03:50
Glad to hear you squared that away.

JF1980
May 16th, 2005, 16:00
p-chan! sorry to but in to a different conversation like this but I have been trying to contact you, I would really love to know what is on the page you refer to which solved your poptop issues? Unfortunately the page is no longer active and I have the exact same problems you were having! CAn you help me out???

Many Thanks,

Justin.