jedaffra
January 15th, 2003, 14:54
Hi,

I installed Open on a laptop two nights ago. For the most part the install went great although I did run into some minor (i hope) issues. I've got two Intel Pro 100 pcmcia cards in the machine, however, when going through the network configuration section of the install I ran into problems.

-The install instructions state: "If any interface will be configured by DHCP, you should not enter infformation that will be supplied via DHCP, e.g. the DNS domain name". So, when I was asked to "Enter the DNS domain name" I hit the enter key for the default option [my.domain] as I don't have an available domain name to use. Also, I was hoping by using DHCP I would get that info from my cable provider (I've never setup Openbsd as a dhcp client before so bear with me).
-Next, I was expecting to see two network interfaces in the "Available interfaces section:", however I was told that there were no available interfaces (?) :shock:

So, I carry on and complete the rest of the install without incident. I reboot and check my dmesg, which tells me I have two pcmcia cards (fxp0 and fxp1). I have fxp1 plugged into the cable modem (I can tell from the mac address) so I do a man afterboot and man dhcp and find out about dhclient.conf.

I fire up Vi and create a hostname.fxp1 file that contains only this text: dhcp. Next, I uncomment the following lines in my /etc/dhclient.conf:
request subnet-mask, broadcast-address, time-offset, routers, domain-name,
domain-name-servers, host-name, lpr-servers, ntp-servers;

require subnet-mask, domain-name-servers, routers;

I reboot and ping a couple of known IP address with 100% success. However, when attempting to FTP or DIG this is what I get:
"non-recoverable failure in name resolution"

As I mentioned above, my DHCP client experience with OBSD is non-existant so I assumed that by uncommenting the lines in dhclient.conf, I would not need to set-up a mygate file in /etc (I was hoping the dhclient.conf file would grab gateway info from the cable modem).

An ifconfig -a shows the following fxp0: flags=8802 [BROADCAST,SIMPLEX,MULTICAST] mtu 1500
address: "fxp0 mac address"
media: Ethernet autoselect (10baseT)
status: active

fxp1: flags=8843[UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST] mtu 1500
address: "fxp1 mac address"
media: Ethernet autoselect (100baseTX full-duplex)
status: active
inet6 fe80::203:47ff:fe18:76fc%fxp1 prefixlen 64 scopeid 0x15
inet xxx.xxx.xxx.xxx netmask 0cfffffc00 broadcast 24.222.103.255

Also, netstat -rn lists the correct default gateway address (from the cable provider) for my main interface (fxp1).

So, I think I'm close to getting this thing 100% live but could use a push in the right direction.

Thanks and sorry for the long post :roll:

frisco
January 15th, 2003, 17:43
the only error you were getting is the name resolution failure, right? what are the contents of your /etc/resolv.conf file?

jedaffra
January 15th, 2003, 21:53
the only error you were getting is the name resolution failure, right?
Yes thats true

what are the contents of your /etc/resolv.conf file?
I don't have this file, didn't realize I needed it when acting as a DHCP client. I'm guessing this is the cause of my grief?

What should this file contain if I'm setting up this machine as a DHCP client? I'm confused about configuring a file when I thought my networking information is to be provided dynamically by the "cable guys".

Thanks frisco.

frisco
January 17th, 2003, 02:23
dhclient should create /etc/resolv.conf for you. i think your dhcp server is not providing you with the dns info the way that dhclient wants it. if you create a valid /etc/resolv.conf file, you will solve the problem you are seeing, but then you'll have to update that file whenever the relevant info changes.

jedaffra
January 17th, 2003, 09:21
dhclient should create /etc/resolv.conf for you.
Cool...
i think your dhcp server is not providing you with the dns info the way that dhclient wants it.
That could (possibly ?) explain the following output I get when typing "dhclient" at the prompt:

ifconfig: SIOCAIFADDR: Invalid argument
ifconfig: SIOCAIFADDR: Invalid argument
ifconfig: SIOCAIFADDR: Invalid argument
ifconfig: SIOCAIFADDR: Invalid argument
Listening on BPF/fxp1/"mac address"
Sending on BPF/fxp1/"mac address"
Jan 16 17:12:31 saphire dhclient: Can't find free bpf: Device not configured
Can't find free bpf: Device not configured
Jan 16 17:12:31 saphire dhclient:exiting

if you create a valid /etc/resolv.conf file, you will solve the problem you are seeing, but then you'll have to update that file whenever the relevant info changes.

Bummer, but again, I appreciate the info. Stay tuned... :)

bsdjunkie
January 17th, 2003, 09:43
Found the follwoing post with google. hope it helps.


will assume that when you try to configure the 2nd interface you
see an error message like:

Can't find free bpf: No such file or directory
exiting.

Because the ramdisk kernels are configured by default with only a
single bpf device, and each running dhclient 'consumes' one bpf
device, and configuring an interface with dhcp leaves a dhclient
process running, well you can do the math. :-).

You can probably get around the problem by exiting to a shell with
'!', and killing the running dhclient (see /var/run/dhclient.pid since
ps may not be available). Now the 2nd interface can probably be
configured with dhcp.

Alternatively you can change RAMDISKxx to have more bpf devices and
generate a new boot image for your system.

The GENERIC kernel has 8 bpf devices so it will work up to that many
concurrent dhclient processes.

.... Ken

The problem you are probably encountering is that there is only one
bpf device configured in the ramdisk kernels. dhclient uses one per
invocation (and currently each invocation of dhclient sticks around
indefinately), and so the 2nd and subsequent invocations of dhclient
during the install process will fail.

frisco
January 17th, 2003, 09:56
does the bpf problem happen during install or once your system is up and running? if after up and runnng, were there any other problems once you were up and running? how many interfaces do you have in that machine? since GENERIC has 8 bpf's defined, you shouldn't reach that error unless you're really doing some intricate networking or Something Bad happened during install (like, you exited before all devices were made)

once you are up and running, you can check /dev for your bpf devices: `ls /dev/bpf*`
you should see 10 devices created.

then you can check your kernel for their support:
config -e /bsd
ukc> find bpf
265 bpfilter count 8 (pseudo device)

if you dont see 'count 8' then are you running GENERIC? what is the output you see?

good luck,

jedaffra
January 17th, 2003, 11:46
Hey Junkie et Frisco,

does the bpf problem happen during install or once your system is up and running?
The only time I see the bpf error is when i run dhclient at the prompt. I didn't *notice* the error on install so I can't say for sure if it happened then or not.

I did encounter a single anomaly during this install - section 4.3.3 on www.openbsd.org/faq/faq4.html#Network is the section entitled "Configuring your Network". This is the part of the OpenBSD install where network interfaces are supposed to be detected, however, both of these cards were not detected - it said no interfaces available (not the exact wording but very close). I carried on with the rest of the install without incident. After the first reboot I checked dmesg and both cards (fxp0 et fxp1) were listed. I am currently at work and don't have access to a copy of this dmesg, but will get it and post it tonight.

if after up and runnng, were there any other problems once you were up and running?
No, again not that I've noticed (the ftp and dig errors excluded).

how many interfaces do you have in that machine?
The laptop has two identical pcmcia cards (Intel Pro 100) installed - one in each slot. I want the cable modem to feed directly into one card (dhcp) while I want the second card to feed the switch for the rest of my network (pf and nat).

once you are up and running, you can check /dev for your bpf devices: `ls /dev/bpf*`
you should see 10 devices created.

then you can check your kernel for their support:
config -e /bsd
ukc> find bpf
265 bpfilter count 8 (pseudo device)

if you dont see 'count 8' then are you running GENERIC? what is the output you see?
Tonight I'll also check 'ls /dev/bpf*' for 10 devices, check the kernal for their support (I'm 99% sure I'm running the GENERIC kernal) and definately get back to you.

The problem you are probably encountering is that there is only one
bpf device configured in the ramdisk kernels. dhclient uses one per
invocation (and currently each invocation of dhclient sticks around
indefinately), and so the 2nd and subsequent invocations of dhclient
during the install process will fail.
I'm not sure what to do if this is the case :?

FYI, I am dual-booting this laptop between Win2k and OpenBSD using GAG as a boot manager/loader and have had nothing but success in this regard so far. When I boot into Win2k partition the interface connected to the cable modem (fxp1) had no problem getting all of the pertinent dhcp info from my provider and I am able to surf. I've tried releasing all dhcp configured card settings in Win2k and immediatley rebooting into OpenBSD but this had no positive effect towards resolving this problem.

Thanks again.

jedaffra
January 17th, 2003, 18:51
once you are up and running, you can check /dev for your bpf devices: `ls /dev/bpf*`
you should see 10 devices created.
Yes, there are 10 devices listed: /dev/bpf0 - bpf9

once you are up and running, you can check /dev for your bpf devices: `ls /dev/bpf*`
you should see 10 devices created.

then you can check your kernel for their support:
config -e /bsd
ukc> find bpf
265 bpfilter count 8 (pseudo device)

if you dont see 'count 8' then are you running GENERIC? what is the output you see?
OpenBSD 3.2 (GENERIC) #25: Thu Oct 3 19:51:53 MDT 2002
deraadt@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
warning: no output file specified
Enter 'help' for information
ukc> find bpf
265 bpfilter count 8 (pseudo device)

What do you think? I think I'm gonna do a reinstall and see what happens with just one card this time - see if I can reproduce my network install troubles. :roll:

Maybe OpenBSD just doesnt like this IBM ThinkPad 385XD...

jedaffra
January 17th, 2003, 22:52
My apologies for not noticing this sooner but I think this line in my dmesg is a BIG clue to this problem:

cbb1: bad Vcc request. sock_ctrl 0x30, sock_status 0x30000b20

I searched google groups and found a few "bad Vcc request" questions and even fewer answers, sigh. I'm no kernel hacker and I've tried 2 re-installs with no joy. Curses. I think I'll try plugging in the last known good dhcp info I pulled off the card when I booted this thing into windows and just hard wire it into my obsd partition. :roll:

frisco
January 17th, 2003, 23:36
yeah that dmesg output is a definite clue - cbb is your CardBus device, interfacing into the fxp's. you might want to send a bug report. you might also want to google for your make of laptop and openbsd, perhaps someone has a work around.