[Printable]
Share

Muddy Linux

Posted: Tue 23rd October 2007 in Blog

muddy linux logo

A small linux distro, developed from pebble linux from New York Wireless, designed to be booted from a 128 Meg CF card.

This was used for at least 2 years to run PierToPier.net's seafront wifi network in Brighton. Put in an appearance at the Glade festival.

ultimatly its just tweaked Pebble linux, however its does have some differences.

DOWNLOAD

muddy 0.4 beta

old versions might be on piertopier.net's download page

Basics

It doesn't exactly "Mesh" but it comes close. As it was originally built the installer creates either a Gateway (wired connection to the internet) or a repeater. The repeater uses a static default route and uses OSPF to advertise the fact. The Repeater uses OSPF to find a default route.

Both automatically build a bridge of WDS access points in range. This may not be suitable. On first live test it built 12 WDS links to other random access points. The auto wds function should be turned of!  

Both gateway and repeater service clients via the chillispot captive portal system

Here's the Out of Date Readme.....

 

README

PierToPier.net “Muddy” Pebble Notes.
By Tom Griffiths, with help from Chris Wilson, Dave Phelan and Ben PierToPier.net 2006 GNU License V2 and all that.

What is “Muddy”?
Its just our customized version of Pebble linux (NY Wireless http://www.nycwireless.net/ pebble)

Where Can I get it?
 Probably on our Wiki.(wiki.piertopier.net) or Tom's site http://www.oceanhippie.net

What do I need to run it,
Dunno 486 with a few meg of ram and a 128 meg flash card. To make it WDS with stuff you need a PRISM II based wifi card, and you need to flash its station firmware to greater than 5.6.(see http://linux.junsun.net/ intersil-prism/)

How do I install it?
Same way you install pebble, from linux. Windows users dunno, virtual machine?
tar -xvzf muddy-0.1.tar.gz to extract it
change dir to where ever you extracted it and type “./muddy.update”
Follow the instructions, If your running MiniITX, then use option 1, this loads hostap_pci and via-rhine drivers. Option 2 loads via- rhine, ath_pci and hostap_pci drivers option three loads every net driver I could think of for generic PC's.

How Does muddy differ from Pebble?
Its got more bits principally
SNMPD
netcat
Chillispot instead of nocat, (and bits it needs to run)
p2pcheckin scripts.
customized wds scripts / networking scripts. principally /etc/ init.d/bridge (by me) and /etc/ init.d/wds (from Sown http://www.sown.org.uk/)
extra /dev/ entry for the tun interface.

How does it work.
Depending how you configure it, it fires up the wireless card and automatically creates WDS links to any (change this using the /etc/network/wds config file) accesspoint on its channel.
Then it builds a bridge, of wlan0 and any WDS devices in range. Then uses zebra/OSPF (/etc/ zebra/ospfd.conf and zebra.conf) to build its routes, if its got a wired Internet connection zebra sets that as the default route, then OSPF advatises that node as a gateway to other WDS links. If zebra isn't set with a default route OFPF will find one off another WDS links. Bridges are running STP (spanning tree protocol) to stop bridge loops.
Finally it starts up chillispot and authentication system, radius client/nas, dhcp captive portal. This creates a tun0 interface and services clients off it.
There's a firewall (/etc/init.d/firewall), basically the one supplied with chillispot. Does nat etc.

No really how does it work, whats a tun interface? why wouldn't I want a Bridge loop?
F***ed if I know I'm a physics laboratory technician for 16 to 18 year olds, not an expert.

What do I need to change?
Not Much the Installer should set it all up ready to go. However the following have been tweaked by and if you gwet stuck have a go at them.
/etc/modules – hardware, if you chose the right install option, you shouldn't need to change this, this is what drivers are loaded on boot. (ath_pci for atheros – no WDS at present)
  / etc/network/interfaces – network cards config (note wifi interface ip is overridden by the bridge its a backup) specify the ssid etc here.
/etc/network/wds – wds configuration
/etc/init.d/bridge – wireless bridge configuration and management script
/etc/zebra/zebra.conf make sure it matches /etc/network/interfaces. If gateway add default route here.
  /etc/zebra/ospfd.conf if gateway uncomment default information-originate, so it tells WDS devices its a gateway. otherwise should match /etc/network/interfaces configuration.
/etc/hosts. WARNING chillispot will NOT start unless it can resolve any domain names in its config file. Since OSPF takes a while to find a default route make sure any domain used in chilli.conf are in here.
/etc/init.d/chilli.conf captive portal configuration, you can use chillispot's radius and splash for practice (http://www.chillispot.org).
Choose your firewall configuration, /etc/init.d/firewall for a gateway, firewall.repeater for a repeater.
some of the settings the isntall make us are piertopier.net specific. If you want to change the INSTALLER settings then edit the files in /sample. Leave the phrases like "REPLACEWITHNODENO" and simailr as they are used by the installer.

Sounds great does it work?
Sort of. Things I know are broken:
Repeater Firewall doesn't actually work – I'm no good at iptables. Just turn it off and chilli off and the central gateway will splash 'em, I got this to work on OpenWRT
cron runs "/etc/init.d/bridge rebuild” to create and add/remove new/lost WDS links to/from the wireless bridge. I use static WDS declaration in /etc/network/wds anyway. Its wds'ing is a bit virulent. It will WDS with anything. First time I tried it gave me an ip off a neighboring meashap box!.

How secure is it?
Not at all, what do I know I clean test-tubes for a living? OK anything with an IP on the backhaul net (i.e. NOT DHCP'd from chillispot) can access the Internet. All you have to do is assign yourself a free IP on this net and your free to go. This is partly deliberate, its in development – I Need it for when I screw up. Ultimately some sort of ip tunnel for backhaul instead is wise... I don't do ipsec....

Why do it this way?
Errrrrrrr what is it with the difficult questions? BUT its compatible with OpenWRT (use PierToPier.net “rusty” and it will talk to a linksys WRT54G in WDS mode :-) which is cool.
Chillispot does radius accounting :-), which is really cool (stats.piertopier.net) we already had the hardware. MeshAP(www.locusworld.net) was driving me nuts, and it was the best I could do!

BIG FAT WARNING.
  Do not try this if your not competent at networking, linux, wifi and for gods sake don't try it near any sensitive people/equipment.

RELEASE NOTES

Muddy Release Notes:
Muddy Linux pre 0.3
0.3 Release
  Firewall settings finally sorted, Chillispot runs on Repeater Nodes, OSPF decides which gateway to use.
Installer Sets up firewall for repeater/gateway.
Webcam has been tested with 0.3
WEBCAM MINI HOWTO
apt-get update
apt-get install vgrabbj
edit /etc/vgrabbj.conf - warning so of these options will toast your card!
you may need to create /dev/video
Madwifi appears to be working
  Compatibility testing:
Muddy 0.3 has been tweaked to run on: EBX, MiniITX, old Celeron 366, IBM thinkpad 560. Every Prism2 card I can get my hands on works fine with this. Pretty sure that the CF ones will work too.

BUGS:
Wireless tools package will NOT talk to Madwifing properly. I'm testing this before I put it in the build. apt- get isntall wireless tools seems to work.
  Madwifi-ng crashes the kernel surprise surprise....
------------------------------------------------------------------------
0.2 Release
  New Kernel (2.4.27- muuddy 0.1), support for v4l and usb webcams based on ov511 and stv60.
  New hostap Driver, with firmware download support.
New Madwifi drivers, moved over to the new Madwifi-ng driver.
Auto Prism2 firmware upgrade on boot /etc/ init.d/firmware config in /etc/network/firmware selection of firmware in /usr/lib/firmware
Bridge Script improved. It functions as before however it DOES NOT require Its IP to be se manually anymore, it gets it from ifconfig. Its other settings have been moved to a config file / etc/network/bridge however its not expected that these will need to be changed (unless we go to atheros cards)
PCMCIA (well some)

BUGS:
Missing wlanconfig prog for madwifi so anything bar client mode don't work - will probably be fixed before full release.
TMPFs much improved. ksmoops main culprit.
  not expecting the zebra bug again, typeo in old configs I suspect.
  PCMCIA alecs 16 bit thingy works my card bus one doesn't
Repeater Firewall

------------------------------------------------------------------------
O.1 Release

NEW THINGS:
  /usr/sbin/logclean and its cron job. Don't tell Dave but p2pcheckin is more important than log data I can't understand. Its only mildly deleted once a day.
  Icreased the size of /rw the tmpfs to 20 meg as all boxes have >128 meg of ram. Until the log thing is under control
Rmoved the link to the firewall. Needs to be put back ofr a gateway only (cd to /etc/rc2.d and ln -s ../init.d/firewall S99firewall
needs to be added for a gateway.
  New installer, won't know if it works till after this is writern. I'm building this as arelease in case I've done something dumb and the script decimates the build dir.
better hardware support from the installer. (both the normal muddy.update and muddy.update.tom)
Hs M-E's DNS set this time.
ppcheckin has full path to urlencode now, which it seems to like

BUGS:
Still no smart repeater. Disable chilli on a repeater.
Runs out of tmfs which is irritating
deleting stuff from tmpfs doesn't seem to free up hd space WTF?
  f you put an atheros card in for backhaul zebra goes bananas and starts assigning address to lo not wlan0 which is annoying.

 

 

 

[Printable]
Share

Muddy Linux

Posted: Tue 23rd October 2007 in Blog

Muddy Linux

muddy linux logo

A small linux distro, developed from pebble linux from New York Wireless, designed to be booted from a 128 Meg CF card.

This was used for at least 2 years to run PierToPier.net's seafront wifi network in Brighton. Put in an appearance at the Glade festival.

ultimatly its just tweaked Pebble linux, however its does have some differences.

DOWNLOAD

muddy 0.4 beta

old versions might be on piertopier.net's download page

Basics

It doesn't exactly "Mesh" but it comes close. As it was originally built the installer creates either a Gateway (wired connection to the internet) or a repeater. The repeater uses a static default route and uses OSPF to advertise the fact. The Repeater uses OSPF to find a default route.

Both automatically build a bridge of WDS access points in range. This may not be suitable. On first live test it built 12 WDS links to other random access points. The auto wds function should be turned of!  

Both gateway and repeater service clients via the chillispot captive portal system

Here's the Out of Date Readme.....

 

README

PierToPier.net “Muddy” Pebble Notes.
By Tom Griffiths, with help from Chris Wilson, Dave Phelan and Ben PierToPier.net 2006 GNU License V2 and all that.

What is “Muddy”?
Its just our customized version of Pebble linux (NY Wireless http://www.nycwireless.net/ pebble)

Where Can I get it?
 Probably on our Wiki.(wiki.piertopier.net) or Tom's site http://www.oceanhippie.net

What do I need to run it,
Dunno 486 with a few meg of ram and a 128 meg flash card. To make it WDS with stuff you need a PRISM II based wifi card, and you need to flash its station firmware to greater than 5.6.(see http://linux.junsun.net/ intersil-prism/)

How do I install it?
Same way you install pebble, from linux. Windows users dunno, virtual machine?
tar -xvzf muddy-0.1.tar.gz to extract it
change dir to where ever you extracted it and type “./muddy.update”
Follow the instructions, If your running MiniITX, then use option 1, this loads hostap_pci and via-rhine drivers. Option 2 loads via- rhine, ath_pci and hostap_pci drivers option three loads every net driver I could think of for generic PC's.

How Does muddy differ from Pebble?
Its got more bits principally
SNMPD
netcat
Chillispot instead of nocat, (and bits it needs to run)
p2pcheckin scripts.
customized wds scripts / networking scripts. principally /etc/ init.d/bridge (by me) and /etc/ init.d/wds (from Sown http://www.sown.org.uk/)
extra /dev/ entry for the tun interface.

How does it work.
Depending how you configure it, it fires up the wireless card and automatically creates WDS links to any (change this using the /etc/network/wds config file) accesspoint on its channel.
Then it builds a bridge, of wlan0 and any WDS devices in range. Then uses zebra/OSPF (/etc/ zebra/ospfd.conf and zebra.conf) to build its routes, if its got a wired Internet connection zebra sets that as the default route, then OSPF advatises that node as a gateway to other WDS links. If zebra isn't set with a default route OFPF will find one off another WDS links. Bridges are running STP (spanning tree protocol) to stop bridge loops.
Finally it starts up chillispot and authentication system, radius client/nas, dhcp captive portal. This creates a tun0 interface and services clients off it.
There's a firewall (/etc/init.d/firewall), basically the one supplied with chillispot. Does nat etc.

No really how does it work, whats a tun interface? why wouldn't I want a Bridge loop?
F***ed if I know I'm a physics laboratory technician for 16 to 18 year olds, not an expert.

What do I need to change?
Not Much the Installer should set it all up ready to go. However the following have been tweaked by and if you gwet stuck have a go at them.
/etc/modules – hardware, if you chose the right install option, you shouldn't need to change this, this is what drivers are loaded on boot. (ath_pci for atheros – no WDS at present)
  / etc/network/interfaces – network cards config (note wifi interface ip is overridden by the bridge its a backup) specify the ssid etc here.
/etc/network/wds – wds configuration
/etc/init.d/bridge – wireless bridge configuration and management script
/etc/zebra/zebra.conf make sure it matches /etc/network/interfaces. If gateway add default route here.
  /etc/zebra/ospfd.conf if gateway uncomment default information-originate, so it tells WDS devices its a gateway. otherwise should match /etc/network/interfaces configuration.
/etc/hosts. WARNING chillispot will NOT start unless it can resolve any domain names in its config file. Since OSPF takes a while to find a default route make sure any domain used in chilli.conf are in here.
/etc/init.d/chilli.conf captive portal configuration, you can use chillispot's radius and splash for practice (http://www.chillispot.org).
Choose your firewall configuration, /etc/init.d/firewall for a gateway, firewall.repeater for a repeater.
some of the settings the isntall make us are piertopier.net specific. If you want to change the INSTALLER settings then edit the files in /sample. Leave the phrases like "REPLACEWITHNODENO" and simailr as they are used by the installer.

Sounds great does it work?
Sort of. Things I know are broken:
Repeater Firewall doesn't actually work – I'm no good at iptables. Just turn it off and chilli off and the central gateway will splash 'em, I got this to work on OpenWRT
cron runs "/etc/init.d/bridge rebuild” to create and add/remove new/lost WDS links to/from the wireless bridge. I use static WDS declaration in /etc/network/wds anyway. Its wds'ing is a bit virulent. It will WDS with anything. First time I tried it gave me an ip off a neighboring meashap box!.

How secure is it?
Not at all, what do I know I clean test-tubes for a living? OK anything with an IP on the backhaul net (i.e. NOT DHCP'd from chillispot) can access the Internet. All you have to do is assign yourself a free IP on this net and your free to go. This is partly deliberate, its in development – I Need it for when I screw up. Ultimately some sort of ip tunnel for backhaul instead is wise... I don't do ipsec....

Why do it this way?
Errrrrrrr what is it with the difficult questions? BUT its compatible with OpenWRT (use PierToPier.net “rusty” and it will talk to a linksys WRT54G in WDS mode :-) which is cool.
Chillispot does radius accounting :-), which is really cool (stats.piertopier.net) we already had the hardware. MeshAP(www.locusworld.net) was driving me nuts, and it was the best I could do!

BIG FAT WARNING.
  Do not try this if your not competent at networking, linux, wifi and for gods sake don't try it near any sensitive people/equipment.

RELEASE NOTES

Muddy Release Notes:
Muddy Linux pre 0.3
0.3 Release
  Firewall settings finally sorted, Chillispot runs on Repeater Nodes, OSPF decides which gateway to use.
Installer Sets up firewall for repeater/gateway.
Webcam has been tested with 0.3
WEBCAM MINI HOWTO
apt-get update
apt-get install vgrabbj
edit /etc/vgrabbj.conf - warning so of these options will toast your card!
you may need to create /dev/video
Madwifi appears to be working
  Compatibility testing:
Muddy 0.3 has been tweaked to run on: EBX, MiniITX, old Celeron 366, IBM thinkpad 560. Every Prism2 card I can get my hands on works fine with this. Pretty sure that the CF ones will work too.

BUGS:
Wireless tools package will NOT talk to Madwifing properly. I'm testing this before I put it in the build. apt- get isntall wireless tools seems to work.
  Madwifi-ng crashes the kernel surprise surprise....
------------------------------------------------------------------------
0.2 Release
  New Kernel (2.4.27- muuddy 0.1), support for v4l and usb webcams based on ov511 and stv60.
  New hostap Driver, with firmware download support.
New Madwifi drivers, moved over to the new Madwifi-ng driver.
Auto Prism2 firmware upgrade on boot /etc/ init.d/firmware config in /etc/network/firmware selection of firmware in /usr/lib/firmware
Bridge Script improved. It functions as before however it DOES NOT require Its IP to be se manually anymore, it gets it from ifconfig. Its other settings have been moved to a config file / etc/network/bridge however its not expected that these will need to be changed (unless we go to atheros cards)
PCMCIA (well some)

BUGS:
Missing wlanconfig prog for madwifi so anything bar client mode don't work - will probably be fixed before full release.
TMPFs much improved. ksmoops main culprit.
  not expecting the zebra bug again, typeo in old configs I suspect.
  PCMCIA alecs 16 bit thingy works my card bus one doesn't
Repeater Firewall

------------------------------------------------------------------------
O.1 Release

NEW THINGS:
  /usr/sbin/logclean and its cron job. Don't tell Dave but p2pcheckin is more important than log data I can't understand. Its only mildly deleted once a day.
  Icreased the size of /rw the tmpfs to 20 meg as all boxes have >128 meg of ram. Until the log thing is under control
Rmoved the link to the firewall. Needs to be put back ofr a gateway only (cd to /etc/rc2.d and ln -s ../init.d/firewall S99firewall
needs to be added for a gateway.
  New installer, won't know if it works till after this is writern. I'm building this as arelease in case I've done something dumb and the script decimates the build dir.
better hardware support from the installer. (both the normal muddy.update and muddy.update.tom)
Hs M-E's DNS set this time.
ppcheckin has full path to urlencode now, which it seems to like

BUGS:
Still no smart repeater. Disable chilli on a repeater.
Runs out of tmfs which is irritating
deleting stuff from tmpfs doesn't seem to free up hd space WTF?
  f you put an atheros card in for backhaul zebra goes bananas and starts assigning address to lo not wlan0 which is annoying.