Establishing a Mesh Portal

From OLPC
Revision as of 02:50, 31 March 2007 by DanWilliams (talk | contribs)
Jump to navigation Jump to search

Establishing a Mesh Portal

It's not entirely automatic quite yet; we'll get a more automatic solution in place soon.

Requirements


What to do

  • Un-gzip and un-tar that somewhere on your mesh portal machine
  • in masquerade.sh from the mpp-utils, change EXTIF to your USB wired interface
  • In masquerade.sh, make the following changes (in patch-style form):
    # This line results in iptables: Unknown error 4294967295
-    #$IPTABLES -A FORWARD -i $EXTIF -o $INTIF -m state --state ESTABLISHED,RELATED -j ACCEPT
+    $IPTABLES -A FORWARD -i $EXTIF -o $INTIF -m state --state ESTABLISHED,RELATED -j ACCEPT
    $IPTABLES -A FORWARD -i $EXTIF -o $INTIF  -j ACCEPT
    $IPTABLES -A FORWARD -i $INTIF -o $EXTIF -j ACCEPT
-    $IPTABLES -A FORWARD -j LOG
+    #$IPTABLES -A FORWARD -j LOG
  • Stop NetworkManager and the 'network' scripts

chkconfig --level 2345 NetworkManager stop chkconfig --level 2345 network stop chkconfig --level 2345 dhcdbd stop

  • reboot
  • Create an ifcfg file for your wired interface. If your wired interface is eth1:

Create /etc/sysconfig/network-scripts/ifcfg-eth1, which should contain:

DEVICE=eth1
ONBOOT=no
BOOTPROTO=dhcp
  • Start the wired interface
ifup eth1
  • Configure the mesh interface
iwconfig msh0 mode ad-hoc channel 11 essid "olpc-mesh"
  • Assign the address to the mesh interface
ifconfig msh0 169.254.1.1 up
  • Delete the 169.254/16 route on the wired interface
ip route del 169.254.0.0/16 dev eth1
  • run the mpp.py script
python mpp.py

and it should all work