Adding Wireless Client Support to Bering

By default, Bering does not include support for wireless devices. Remember, it ships in a configuration that assumes you are using two wired Ethernet cards. That's fine if you are going to put the Bering device in between your cable modem/DSL and your existing AP. However, another possible configuration is to use one wired Ethernet card (for the cable modem/DSL) and a WLAN card for the other interface.

If you are using a laptop for your hardware, it will probably already have a PCMCIA slot for your wireless NIC. If your hardware is a desktop PC, you will need an adapter to go from your bus (ISA or PCI) to a PCMCIA interface, or, you can purchase a wireless card already in a PCI form factor. In order for this to work, you'll need to add a few modules and packages. The problem you're bound to run into is the size limitation of the floppy disk. The Bering floppy simply isn't large enough to contain all the files you will need to add, so our first step is to create a distribution that will span across two floppy disks.

Caution

Keep in mind that each floppy needs to be the same size (1.44, 1.68, etc.). I suggest you use the boot disk creation program that you used to make your original boot disk and make a second boot disk. Then, you can delete all the files and you'll be left with a blank, 1.68 MB formatted floppy disk. If you get an Access is denied error message, use the attrib command in MS-DOS to remove the read-only status of that file.

Alternatively, if you want to create a super 1.68 floppy, you can use the Linux command superformat /dev/fd0u1680. For Windows machines, you can use a program called WinImage from http://www.winimage.com.


Here's the plan: Put the following files on your boot floppy: linux, ldlinux.sys, syslinux.dpy, syslinux.cfg, and initrd.lrp. Then, put all of the other .lrp files on your second floppy. You'll also need to make some changes to the syslinux.cfg file. In the line that starts with default linux, you need to add the command diskwait=yes in between the boot= statement and the PKGPATH= statement. It should look something like this when you're done:

default linux initrd=initrd.lrp init=/linuxrc rw root=/dev/ram0 boot=/dev/fd0u1680:msdos
 diskwait=yes PKGPATH=/dev/fd0u1680 LRP=root,etc,local,modules,iptables,pump,shorwall,ulogd
,dnscache,weblet

Note that this command must be put on one line (not separated into multiple lines).

Now that you have plenty of space on your floppy disk, it's time to add wireless support. Keep in mind that the steps you need to take will be different depending on what kind of wireless card you have.

Orinoco Cards

First, download pcmcia_orinoco.lrp, wireless.lrp, and libm.lrp from http://leaf.sourceforge.net/devel/jnilo/bering/latest/packages and put them on your second floppy. Rename the pcmcia_orinoco.lrp file to pcmcia.lrp.

Also, get the module wavelan2_cs.o by navigating to http://leaf.sourceforge.net/devel/jnilo/bering/latest/modules, clicking on the appropriate kernel folder (i.e., 2.4.20), and going into the pcmcia folder.

Then, you will need to edit the syslinux.cfg file to include the new packages we just downloaded. Add them to the LRP= section of the default linux line. Also, be sure that the reference to keyboard has been removed from the LRP= section.

For example (remember that you need to put the entire command on one line):

default linux initrd=initrd.lrp init=/linuxrc rw root=/dev/ram0 boot=/dev/fd0u1680:msdos
 diskwait=yes PKGPATH=/dev/fd0u1680 LRP=root,etc,local,modules,iptables,pump,shorwall,ulogd
,dnscache,weblet,pcmcia,wireless,libm

After you've added those packages and rebooted, you'll notice some new files in /lib/modules/pcmcia such as do.o, hermes.o, i82365.o, Orinoco.o, Orinoco_cs.o, and pcmcia_core.o. You'll need to put the wavelan2_cs.o file you downloaded into the /lib/modules/pcmcia folder.

Next, from the LEAF Configuration menu, select Packages configuration, then PCMCIA.

The pcmcia default parameters option will open /etc/default/pcmcia in the text editor. The file should look like this:

PCMCIA=yes

PCIC=i82365

PCIC_OPTS=

CORE_OPTS=

CARDMGR_OPTS=

If you are using a PCMCIA adapter in an ISA/PCI slot, you may need to modify PCIC_OPTS= to read PCIC_OPTS=i365_base=0x3e2.

The wireless configuration option will open /etc/pcmcia/wireless.opts in the text editor. This is where you will enter all of the wireless options for your card, such as SSID, Channel, etc. What this script does is take the MAC address and attempt to autodiscover what kind of card you have. This usually works because the first half of the MAC address represents a unique vendor ID.

To activate the autodiscovery, comment out the lines between START SECTION TO REMOVE and END SECTION TO REMOVE. Then, scroll down to the Lucent Wavelan IEEE section and configure your desired settings. (Remember—you are configuring this wireless card as a client.) I suggest setting the SSID to something a little more catchy than Wavelan Network and set the mode to Ad-Hoc. Comment out the KEY=S:secu1 line (or leave it alone—this is where WEP is configured) and add a line that says CHANNEL=6. Save this file (Control+S) and exit (Control+Q).

Next, you will need to tell Bering about the new interface (remember, by default it is expecting eth0 and eth1 to be wired NICs). From the LEAF Configuration menu, select Network Configuration | interfaces file. This will open the /etc/network/interfaces file in the text editor. Make sure to comment out the auto eth1 line right above the iface eth1 inet static line. This is done because the wireless interface (eth1) is not automatically brought up at the same time as eth0. It is brought up later, when /etc/init.d/pcmcia is executed.

To save all the changes, from the LEAF Configuration menu, type b, then back up pcmcia and etc. Reboot.

Prism Cards

To use a Prism card with Bering, follow essentially the same procedure as with the Orinoco card. However, use pcmcia.lrp instead of pcmcia_orinico.lrp and get wlan-ng.lrp. You don't need wavelan2_cs.o, but you will need to put prism2_cs into /lib/modules/pcmcia, put p80211.o in /lib/modules, and call it from /etc/modules.

Fun with Bering

This is just the start! Visit the Bering section at http://leaf.sourceforge.net to find more exciting ways to use your new Bering box. In particular, notice that there are many packages and modules available to support things like DHCP servers, IPSec, PPTP, VLANs, HostAP (to turn your wireless card into an access point) and more.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.22.77.149