Wiki Navigation

Automated VAP creation

MadWifi support multiple VAPs. If you are using MadWifi-old, then this section is not useful, as it deals with the handling of the special abilities of MadWifi-NG within the Debian networking scripts.

Any snapshot more recent than r1407 will create a sta mode VAP for each atheros device by default. If a madwifi-ng-base package is currently installed, please remove it and upgrade your madwifi packages.

To disable the autocreation behaviour:

# echo "options ath_pci autocreate=none" > /etc/modprobe.d/madwifi

Or you may specify a mode in [sta|ap|wds|adhoc|ahdemo|monitor]:

# echo "options ath_pci autocreate=ap" > /etc/modprobe.d/madwifi

Matt Brown has written some more advanced scripts to nicely integrate the madwifi-ng setup with the Debian ifupdown framework. They use the wireless-tools extensions to determine the mode to create the interface in. These are most useful for creating multiple VAPs, especially in ap mode. It may be useful to disable the autocreation of the sta VAP when using these. They are included in the madwifi-tools package and are also available separately from:

Thus avoiding the requirement of third-party scripting to handle the devices.

Interfaces

The /etc/network/interfaces file is the standard Debian method of controlling network interfaces. This file is well documented in the Debian distribution, both internally and by external sources. These include:

The following paragraphs will consist of a handful of example interfaces entries for using MadWifi devices. For each possible command parameter of iwconfig you can include an option in /etc/network/interfaces named like that parameter with a "wireless-" prefix. Wireless devices are more complex to setup correctly, because of the nature of their usage, and the broad range of features available to them. For example, some of them are removeable and some support multiple VAPs (madwifi-ng). Therefore, some special handling is required to exploit as much as possible out of these features.

Client to an access point (essid of "wep.net") with WEP security, using wireless-tools and obtaining an IP via DHCP:

So when the CardBus card generates a hotplug event, the networking scripts are hooked and bring it up. This can be useful even if you're wireless device is permanently installed, for instance, if you have a laptop and want to be remove and reload the kernel modules, e.g., during sleep states.

Advanced Mobile Users Configuration

Debian Etch includes wireless roaming using a wpa_supplicant and feature called wpa-roam. In this case, the stanza in /etc/network/interfaces might look like: