| 1 |
Netsukuku on OpenWRT |
|---|
| 2 |
|
|---|
| 3 |
http://netsukuku.freaknet.org/openwrt |
|---|
| 4 |
|
|---|
| 5 |
|
|---|
| 6 |
This is the package of Netsukuku compiled for Openwrt. |
|---|
| 7 |
|
|---|
| 8 |
This is not official release of the .ipkg package, it's just the |
|---|
| 9 |
one we're using to test it on the WRT. |
|---|
| 10 |
|
|---|
| 11 |
|
|---|
| 12 |
How to install it: |
|---|
| 13 |
(these steps have been used for a Linksys WRT54GL, but once you've |
|---|
| 14 |
installed OpenWRT on your AP, they should be same) |
|---|
| 15 |
|
|---|
| 16 |
#- Install the default OpenWrt firmware: |
|---|
| 17 |
|
|---|
| 18 |
http://wiki.openwrt.org/InstallingWrt54gl |
|---|
| 19 |
|
|---|
| 20 |
#- Activate boot_wait |
|---|
| 21 |
|
|---|
| 22 |
ssh root@openwrt |
|---|
| 23 |
nvram boot_wait=on |
|---|
| 24 |
nvram commit |
|---|
| 25 |
|
|---|
| 26 |
#- Remove useless things |
|---|
| 27 |
|
|---|
| 28 |
ssh root@openwrt |
|---|
| 29 |
rm /etc/init.d/S50telnet |
|---|
| 30 |
|
|---|
| 31 |
#- Optional step: No password, use the ssh keys |
|---|
| 32 |
# (skip this if you don't like it) |
|---|
| 33 |
|
|---|
| 34 |
scp .ssh/id_rsa.pub root@router:/tmp |
|---|
| 35 |
ssh root@192.168.1.1 |
|---|
| 36 |
|
|---|
| 37 |
cd /etc/dropbear |
|---|
| 38 |
cat /tmp/id_*.pub >> authorized_keys |
|---|
| 39 |
rm /tmp/id_*.pub |
|---|
| 40 |
chmod 0600 authorized_keys |
|---|
| 41 |
|
|---|
| 42 |
cd /etc/init.d |
|---|
| 43 |
rm S50dropbear |
|---|
| 44 |
cat /rom/etc/init.d/S50dropbear | grep -v ^/usr/sbin/dropbear > S50dropbear |
|---|
| 45 |
echo /usr/sbin/dropbear -s >> S50dropbear |
|---|
| 46 |
chmod 755 S50dropbear |
|---|
| 47 |
|
|---|
| 48 |
#- Configure the AP to reach the Internet |
|---|
| 49 |
|
|---|
| 50 |
ssh root@openwrt |
|---|
| 51 |
|
|---|
| 52 |
#add a nameserver in /etc/resolv.conf |
|---|
| 53 |
echo nameserver 1.2.3.4 >> /etc/resolv.conf |
|---|
| 54 |
|
|---|
| 55 |
#set the ip to the ethernet-if and add a default gw: |
|---|
| 56 |
nvram lan_gateway=192.168.1.1 |
|---|
| 57 |
nvram lan_netmask=255.255.255.0 |
|---|
| 58 |
nvram lan_dhcp=0 |
|---|
| 59 |
nvram lan_dns=151.97.6.1 |
|---|
| 60 |
nvram lan_ipaddr=192.168.1.X |
|---|
| 61 |
nvram lan_proto=static |
|---|
| 62 |
nvram commit |
|---|
| 63 |
reboot |
|---|
| 64 |
|
|---|
| 65 |
#remember that now the wired IP of the AP is `lan_ipaddr' when you boot it. |
|---|
| 66 |
|
|---|
| 67 |
#- Install the package |
|---|
| 68 |
|
|---|
| 69 |
scp netsukuku_<package_version>.ipk root@openwrt: |
|---|
| 70 |
ssh root@openwrt |
|---|
| 71 |
ipkg install netsukuku_<package_version>.ipk |
|---|
| 72 |
|
|---|
| 73 |
#- Install additional modules |
|---|
| 74 |
|
|---|
| 75 |
#install the ipip module |
|---|
| 76 |
wget http://www.linuxops.net/ipkg/kmod-ipip_2.4.20_mipsel.ipk |
|---|
| 77 |
ipkg install kmod-ipip_2.4.20_mipsel.ipk |
|---|
| 78 |
mv /lib/modules/2.4.20/kernel/net/ipv4/ipip.o /lib/modules/2.4.30/ |
|---|
| 79 |
echo ipip > /etc/modules.d/20-ipip |
|---|
| 80 |
rm kmod-ipip_2.4.20_mipsel.ipk |
|---|
| 81 |
insmod ipip |
|---|
| 82 |
|
|---|
| 83 |
ipkg install ip |
|---|
| 84 |
ipkg install wl |
|---|
| 85 |
|
|---|
| 86 |
#- Remove the firewall |
|---|
| 87 |
|
|---|
| 88 |
ssh root@openwrt |
|---|
| 89 |
rm /etc/init.d/S45firewall |
|---|
| 90 |
reboot |
|---|
| 91 |
|
|---|
| 92 |
#- Set the adhoc mode for your wifi cards |
|---|
| 93 |
|
|---|
| 94 |
nvram wl0_infra=0 |
|---|
| 95 |
nvram wl0_mode=sta |
|---|
| 96 |
nvram wl0_ssid=netsukuku |
|---|
| 97 |
nvram commit |
|---|
| 98 |
|
|---|
| 99 |
#- Now launch netsukuku |
|---|
| 100 |
|
|---|
| 101 |
#give a try with |
|---|
| 102 |
ntkd -i eth1 -ddddd -D -a -R |
|---|
| 103 |
|
|---|
| 104 |
#then with |
|---|
| 105 |
ntkd -i eth1 -ddddd -D |
|---|
| 106 |
|
|---|
| 107 |
/* |
|---|
| 108 |
* TODO: |
|---|
| 109 |
* - remote syslog |
|---|
| 110 |
* http://wiki.openwrt.org/MiniHowtos#head-2f41030163df5954cafe1d1ec8001dc27c4cbba7 |
|---|
| 111 |
*/ |
|---|