Friday, November 27, 2009

The first FreeBSD upgrade to ever piss me off

I built world, two kernels: (my custom) VIPER, and GENERIC. I took about 2 hours using make -j6 on my lowly Sempron.

Fetched updates to the ports tree via portsnap while waiting for the install kernel to finish; I noticed that the boot into single user mode for mergemaster'ing was blazingly fast. Everything went well until the first multi user boot.

The blasted wireless card stopped working. Changing in the ath manual and the release notes info about Atheros support made me expect there might be problems. Plugged in a spare (broken) Ethernet cable and did a search on the FreeBSD forums where a thread mentioned cloning the wireless interface to a generic wlan0.... it worked.

ifconfig wlan0 create wlandev ath0

and volia!


So, just how did this creep up on me, and why wasn't it in the release notes... (that anyone I know seems to have noticed)???

The manual for rc.conf explains this under network_interface:

If a wlans_ variable is set, an wlan(4) interface
will be created for each item in the list with the wlandev
argument set to interface. Further wlan cloning arguments
may be passed to the ifconfig(8) create command by setting
the create_args_ variable. One or more wlan(4)
devices must be created for each wireless devices as of
FreeBSD 8.0. Debugging flags for wlan(4) devices as set by
wlandebug(8) may be specified with an wlandebug_
variable. The contents of this variable will be passed
directly to wlandebug(8).

which makes the fix in rc.conf, adding wlans_interfacename="wlan0" into the mixture:

wlans_ath0="wlan0"      
ifconfig_wlan="self censored :-P"


In order to find some backstory in /usr/src/UPDATING, I had to GREP for it:

20080420:
The 802.11 wireless support was redone to enable multi-bss
operation on devices that are capable. The underlying device
is no longer used directly but instead wlanX devices are
cloned with ifconfig. This requires changes to rc.conf files.
For example, change:
ifconfig_ath0="WPA DHCP"
to
wlans_ath0=wlan0
ifconfig_wlan0="WPA DHCP"
see rc.conf(5) for more details. In addition, mergemaster of
/etc/rc.d is highly recommended. Simultaneous update of userland
and kernel wouldn't hurt either.

As part of the multi-bss changes the wlan_scan_ap and wlan_scan_sta
modules were merged into the base wlan module. All references
to these modules (e.g. in kernel config files) must be removed.



If changing from FreeBSDs natural to wlan for that makes one damn lick of sense what so ever (eth0 lovers aside), I will leave it to someone who knows to comment.... because I don't know, and I don't really give a fart.


The release notes in provides two helpful sentences: wlan pseudo devices are now used and check out the ifconfig manual.


Other then wasting an two hours of my time over a change that probably isn't even the bloody handbook yet, everything went smoothly.

No comments:

Post a Comment