Linux in a Wireless World

Take a look at the wireless networking options that Linux offers.

By Stew Benedict | Posted Nov 15, 2000
Page 1 of 3
Print ArticleEmail Article
  • Share on Facebook
  • Share on Twitter
  • Share on LinkedIn

Want to join the wireless networking revolution, but you're running Linux? Not to fear! Linux has plenty of support for wireless networking devices. In this article, I'll review your wireless options.

The Wireless Networking Page

Your first stop should be the Linux Wireless Networking page. This page gives a pretty comprehensive look at the various hardware and software options available. Once you've reviewed the options, you need to decide how you want to implement wireless in your particular scenario. There are a couple of ways to go: You can use ad-hoc mode, which is a peer-to-peer setup; or you can install an access point to tie into your normal network. Thanks to Linux's flexibility, you can use the ad-hoc connection to implement the latter with a little routing magic.

On my network, I ended up with a pair of Compaq 2Mbps PCMCIA wireless cards, with a pair of PCI adapters that accept the cards. On my laptop, I use the card; on the server, I use the card and the adapter. These cards are based on the Harris Prism chipset, and you can downloaded the necessary software here. You may also need the Linux PCMCIA drivers, which can be found here.

Laptop Setup

To set up a laptop, you'll need the Linux PCMCIA drivers, your kernel sources, and the linux-wlan drivers. You'll also need the kernel source, which is generally in /usr/src/linux. You set up the PCMCIA services as follows. First, as root:

cp pcmcia-cs-3.1.19.tar.gz /usr/src
cd /usr/src
tar -xzf pcmcia-cs-3.1.19.tar.gz
cd pcmcia-cs-3.1.19
make config
make all

If you finish this without errors, then:

make install

Next, set up Wlan, again as root:

cp linux-wlan-0.3.4.tar.gz /usr/src
cd /usr/src
tar -xzf linux-wlan-0.3.4.tar.gz

Now you need to edit config.mk, using your preferred Linux test editor:

LINUX_SRC=/usr/src/linux
PCMCIA_SRC=/usr/src/pcmcia-cs-3.1.19
MODULES_DIR=/lib/modules/2.2.9-19mdk
INST_EXEDIR=/sbin
DESTDIR=
MAKE_ISA=n
MAKE_CS=y

By default, the MAKE_ISA value is y and MAKE_CS is n. However, you want the MAKE_CS value to be , because it's for the PCMCIA card. The Linux kernel stores its modules in the modules entry. The PCMCIA_SRC entry is the directory you created earlier. Save this file and continue:

make clean
make all

If there are no errors, continue with:

make install

Once you make and install wlan, you need to do a couple of manual things:

cp wlan.config wlan wlan.opts /etc/pcmcia
cd /etc/pcmcia
chmod 0755 wlan wlan.opts

The drivers are now in place, and you need to do some configuration work. Let's start with PCMCIA. Under Linux, the PCMCIA drivers run a cardmgr daemon that watches for inserts and removals of cards. Cardmgr looks at the card's signature and configures the system appropriately via shell scripts.

These scripts all reside in /etc/pcmcia, and will use normal system tools to configure the cards by loading/removing appropriate modules and running any other configuration tasks necessary. Like most things in Linux, they are all plain-text scripts, so you can customize them to your liking once you understand how they work.

In addition, a command-line program, cardctl, lets you query and change the card-slot configuration. A GUI application, cardinfo, performs nearly the same tasks, but wrapped in a GUI for X window.

You need to edit /etc/pcmcia/config and add the following line, near the bottom:

source ./wlan.config

You will also need to edit wlan.opts and set up your network configuration. The important lines are as follows:

# Scan for which SSID?
SCAN_SSID=""
DESIRED_SSID="AYS_NET"

# Scan for which BSS and type?
SCAN_BSSID="ff:ff:ff:ff:ff:ff"
SCAN_BSSTYPE=both               # both|ind|infr
SCAN_TYPE=active                # active|passive

# Define scan range
SCAN_STARTCH=1
SCAN_ENDCH=11
SCAN_TIMEPERCHANNEL=100

# Create a BSS if one not detected?
CREATEBSS=no

Essentially, you're saying to scan for Basic Service Set (BSS) AYS_NET at startup, and if it isn't found, to not create your own BSS. The IDs and channels are left at the defaults, so the driver scans all available channels. If you were in a multi-wlan environment, you might want to limit the search appropriately.

For my Compaq cards, there was no appropriate entry in wlan.config, so I had to do some research to create my own.

Comment and Contribute
(Maximum characters: 1200). You have
characters left.
Get the Latest Scoop with Enterprise Networking Planet Newsletter