Orga, Bürokraten, Administratoren
792
Bearbeitungen
Seth0r (Diskussion | Beiträge) |
Seth0r (Diskussion | Beiträge) (rc.local) |
||
Zeile 163: | Zeile 163: | ||
iptables -A INPUT -i eth0 -p udp -m udp --dport 1195 -j ACCEPT | iptables -A INPUT -i eth0 -p udp -m udp --dport 1195 -j ACCEPT | ||
iptables -A INPUT -i eth0 -p udp -m udp --dport 7654 -j ACCEPT | iptables -A INPUT -i eth0 -p udp -m udp --dport 7654 -j ACCEPT | ||
=== /etc/rc.local === | |||
#!/bin/bash | |||
# | |||
# rc.local | |||
# | |||
# This script is executed at the end of each multiuser runlevel. | |||
# Make sure that the script will "exit 0" on success or any other | |||
# value on error. | |||
# | |||
# In order to enable or disable this script just change the execution | |||
# bits. | |||
# | |||
# By default this script does nothing. | |||
killall supernode 2> /dev/null | |||
supernode -l 7654 -v > /var/log/supernode.log 2>&1 & | |||
killall edge 2> /dev/null | |||
N2N_KEY="***key***" edge -b -f -d n2n0 -c pdmvpn -u 99 -g 99 -m CA:FF:EE:BA:BE:0<span style="color:red">X</span> -a 172.22.250.<span style="color:red">X</span> -l vpn.freifunk-potsdam.de:7654 | |||
for dev in tap0 n2n0; do | |||
for prio in 1000 2000 3000 4000 5000; do | |||
ip rule del iif $dev prio $prio | |||
done | |||
ip rule add iif $dev prio 1000 table olsr | |||
ip rule add iif $dev prio 2000 table olsr-tunnel | |||
ip rule add iif $dev prio 3000 table olsr-default | |||
ip rule add iif $dev prio 4000 table pdmvpn | |||
ip rule add iif $dev prio 5000 unreachable | |||
done | |||
ip route flush table pdmvpn | |||
ip route add 172.22.25<span style="color:red">X</span>.0/24 dev tap0 table pdmvpn | |||
ip route add 172.22.250.0/24 dev n2n0 table pdmvpn | |||
killall olsrd 2> /dev/null | |||
/usr/local/sbin/olsrd -f /etc/olsrd/olsrd.conf | |||
exit 0 |