Previous Next Table of Contents

5. Appendicies

5.1 LRP Disks quickstart guide

It is expected for the user to have a _strong_ understanding of how Linux (and UNIX) systems and networks should be configured.

The LRP image in this directory uses a higer density format than is common in the PC world. To accomidate extra software the floppy is formatted for 1722K (instead of the standard 1440K). This format will work fine with modern floppy drives. You will need to make sure you have the file /dev/fd0u1722. If not use the mknod command to create it: 'mknod /dev/fd0u1722 b 2 60'. Next use superformat (if its not on your system use the binary here or download the source and build it) to create the disk: 'superformat /dev/fd0u1722'.

Use dd to install the image on the floppy using:

dd if=wireless-X.X.img of=/dev/fd0u1722

You should also create a bootable arlan configuration disk. Make a msdos bootable floppy and copy the arlancfg.exe onto it. Boot your arlan router box with this disk and configure your io, interrupt and system ID.

Boot your system with the wireless disk. Change your network settings to reflect your configuration. In our case we made our arlan interfaces use the same address as our ethernet interfaces, set a netmask of 255.255.255.255 and used a host-route to connect to the far side of the link. Edit your /etc/hosts, /etc/hostname, /etc/resolv.conf, /etc/gated.conf, /etc/snmpd.conf and other configuration files to your suiting, then use the backup functionality in the LRP configuration program to backup 'etc'.

In the event that your network card is not supported by the out of the box configuration (this is highly likely, as only ne support was included) you will have to add the appropriate modules. Download the kernel-36pre2-1.tar.gz file. Get the appropriate modules out of this archive and put them on your router box in /lib/modules (your methods may vary). Make any appropriate changes in /etc/modues, then back up your 'modules' with the LRP backup program.

5.2 A brief guide to Orienteering

Find out your magnetic declination for your area (probably on the the topo map somewhere). Set your map on a flat surface. Lay your compas on top of the map. Align the north-south line of the compass with the vertical line on the map. Then rotate the map (and compass) the approprate number of degrees for your area (for the bay area that would be rotating it 17' west (left)). Your map is now oriented so that its direction corresponds to the real world.

Next draw a line (with pencil probably) connecting your two nodes. Lay the compass on the line, so that its parallel with the line. Your compass may look something like that below. You now know which way your antennas should point, down to a few degrees. Use these readings to align your antennas.IMPORTANT: make sure your equipment is not up and running while using your compass. The transmitters will interfere with your magnetic compass readings.

o   N
 \  ^
  \ |
   \|
    |
    |\
    | \
       o

5.3 Suppliers

5.4 Host Routing for multiple point to point nodes

Multiple machines can connect via one antenna. My ham radio guy is morally opposed to using omnidirectionals, he says: "The advantage of omnidirectional antennas is that they can hear everything in all directions. The disadvantage of omnidirectional antennas is that they do hear EVERYTHING in all directions."

We've yet to try it, as an omnidirectional antenna would be a rather expensive, and probably non-refundable, experiment. Personally I'm very impressed by the noise rejection characteristics of spread spectrum radio, and would love to try it. Takers, anyone?

Using the spread beam of a directional antenna in your LOS for multiple machines is quite feasable. Just use host based, rather than net based, routing for each of your client machines.

eg:

ifconfig eth0 my_ip_address pointopoint gateway_address
route add -host gateway_address dev eth1
route add -host first_client dev eth1
route add -host second_client dev eth1

and do _not_ add "

route add host -net ....
"

5.5 Greg's Notes

Notes for setting up an LRP router for use in wireless wan's

###Creating the floppy disk###
to create the floppy disk you need several tools..
mtools: tools to copy files onto and off of floppy disks.
fdutils: includes superformat, tool for large format floppies
syslinux: linux floppydisk bootloader

Insert a blank floppy and use superformat to format the floppy as such:
superformat /dev/fd0 sect=21 cyl=80 -V --biggest-last
that will do the large format and verify it
Install the bootloader with the following command line:
syslinux -s /dev/fd0
edit your syslinux.cfg. it should look kinda like this:

display syslinux.dpy
timeout 0
default linux
append=load_ramdisk=1 initrd=root.lrp initrd_archive=minix
ramdisk_size=4096 root=/dev/ram0 boot=/dev/fd0u1680,msdos
LRP=modules,etc,log,gated,snmp

Next copy over your files using mcopy.

###Setting up the modified root###
create a tgz archive called 'extras.lrp'. this should include all your
modules, your tftp client and your pnp client. it should look something
like..

lib/modules/smc-ultra.o
lib/modules/8390.o
lib/modules/arlan.o
lib/modules/ne.o
lib/modules/serial.o
usr/bin/tftp
sbin/isapnp
etc/isapnp.conf
etc/init.d/isapnp
etc/rc2.d/S15isapnp

Make sure all your modules are cross-compiled for the proper version of
the kernel. add extras to LRP= under the 'append' section of
syslinux.conf. 

###Faking serial console###

The changes made to LRP to enable serial consoles to work were the
following:
edit /etc/securetty to include ttyS0
edit /etc/inittab to spawn a getty (9600,8,N,1) on ttyS0
edit /etc/init.d/init.serial (or something) to 'setserial' correctly
edit /lib/makedev.cfg and /lib/devinfo to link console to ttyS0
mknod /linuxrc.tty to reflect the COM1 device (copy from ttyS0)

###Configuring modules###
uncomment serial, uncomment 8390. Then put 'ne io=0x260 irq=5' followed by
a line with 'smc-ultra'. After this you will set up the arlan card with
the proper registration mode and spreading code. Enter 'arlan
registrationMode=0 spreadingCode=3 debug=0' This will have the
machine come up, set up serial, then find either the ne2000 or the SMC nic
card as eth0, and finnaly set up the arlan interface as eth1 (should be
arlan0 at some point).

###network settings###
edit the network settings (IP, fw, etc..). Configure your default GATEWAY,
Set up your IF0(eth0) interface as your ethernet interface. Set up
IF1(eth1) as your arlan interface. Add a value REMHOST1, with the remote
address of the far-end router. Under the section 'Static Network Routes'
add a line: 'route add -host $REMHOST1 gw $IPADDR1'. For some reason IPFW
rules in this file prevent forwarding of packets, a strange default
setting for a router. comment this line out. After editing this
file I suppose you'll wanna customize the hostname too. After you've made
all your edits backup 'etc'.

###More Notes###
ramdisk should be increased from 4096, to perhaps 6144 or 8192. pinion is
at 69% capacity, this could increase with the addition of snmp and gated.
physical ram should also be increased to a minimum of 16 megs. 

###Faking Large Disk###
Add the nfs module to the modules that get installed at runtime. mount
some
remote directory and install the other packages (i.e. gated, snmp).
unmount
and continue as normal. Another possibility is to TFTP over the package
then uncompress it.

###Online Upgrade###
Here is the initial theory for upgrading a router remotely, including an
increased disk size. IMPORTANT: make a backup of your existing image
before attempting this upgrade!

First create the disk with the upgraded software (and larger format, as
required). Use a development box to properly configure this upgraded disk.
The key items to get functional are the serial console ports (most
anything else can be configured from here) and ethernet interface (so that
any missing files can be loaded over the network). It is critical that
this floppy works as expected, as failure would leave the router
unbootable.

* If the upgrade is a different density:
Use tftp to copy a 'superformat' binary onto the router. use this
superformat binary to re-format the floppy disk to the proper density:
superformat /dev/fd0 sect=21 cyl=80 -V --biggest-last
==>problem: ramdisk too small? <==

Next use dd to pull the disk image from your upgraded disk and copy it
into your tftpboot directory...
dd if=/dev/fd0 of=/tftpboot/upgrade.img
Then use tftp on your router to copy this image onto your floppy..

tftp tftphost
tftp> get upgrade.img /dev/fd0

This should pull the image from your tftp server and install it onto your
floppy disk. once this completes, reboot your router. if all goes well it
should come up properly. if not, get out a ladder climb up to your attic
and put in your backup disk. start from scratch.

###Proxy Arp Configuration####
see:
http://tanglefoot.lunatech.com/software/doc/HOWTO/mini/Proxy-ARP-Subnet.gz

Example Network Configuration (assuming assigned block of 1.2.3.0/27)


   #ADSL# <-1.2.3.1/27
     |
-----------------------EverettsHouse
1.2.3.0/27(v28) |
             #WAN0# 1.2.3.2/27 (10.56.57.53/30)
                :
             #WAN1# 1.2.3.17/28 (10.56.57.54/30)
                |
------------------------RedwoodEstates
1.2.3.16/28

WAN0:
# ethernet interface
/sbin/ifconfig eth0 1.2.3.2 netmask 255.255.255.224
/sbin/route add -net 1.2.3.0 netmask 255.255.255.224 eth0
# arlan interface
/sbin/ifconfig arlan0 10.56.57.53 netmask 255.255.255.252
/sbin/route add -net 10.56.57.52 netmask 255.255.255.252 arlan0
# proxy arp and routes
/sbin/route add default gw 1.2.3.1
/sbin/arp -i eth0 -Ds 1.2.3.16 eth0 netmask 255.255.255.240 pub
/sbin/route add -net 1.2.3.16 netmask 255.255.255.240 gw 10.56.57.54

WAN1:
# ethernet interface
/sbin/ifconfig eth0 1.2.3.17 netmask 255.255.255.240
/sbin/route add -net 1.2.3.16 netmask 255.255.255.240 eth0
# arlan interface
/sbin/ifconfig arlan0 10.56.57.54 netmask 255.255.255.252
/sbin/route add -net 10.56.57.52 netmask 255.255.255.252 arlan0
# proxy arp and routes
/sbin/route add default gw 10.56.57.53


Previous Next Table of Contents