forked from freifunk-franken/firmware
Anpassung der Config an OpenWRT 10.03.1
This commit is contained in:
parent
dd36429178
commit
ae9b9edc98
|
@ -1,5 +1,5 @@
|
|||
config 'mesh' 'bat0'
|
||||
option 'interfaces' 'ath1'
|
||||
option 'interfaces' 'wlanmesh'
|
||||
option 'orig_interval'
|
||||
option 'log_level'
|
||||
option 'aggregated_ogms'
|
||||
|
|
|
@ -9,12 +9,11 @@ config 'interface' 'loopback'
|
|||
# option 'ifname' 'eth0.1'
|
||||
|
||||
config 'interface' 'wlanmesh'
|
||||
option 'ifname' 'ath1'
|
||||
option 'mtu' '1528'
|
||||
|
||||
config 'interface' 'mesh'
|
||||
option 'type' 'bridge'
|
||||
option 'ifname' 'eth0.1 ath0 bat0 tap0'
|
||||
option 'ifname' 'eth0.1 bat0 tap0'
|
||||
option 'auto' '1'
|
||||
|
||||
config 'switch' 'eth0'
|
||||
|
|
|
@ -7,6 +7,7 @@ config 'wifi-device' 'wifi0'
|
|||
|
||||
config 'wifi-iface'
|
||||
option 'device' 'wifi0'
|
||||
option 'network' 'wlanmesh'
|
||||
option 'mode' 'adhoc'
|
||||
option 'ssid' 'batman.oldenburg.freifunk.net'
|
||||
option 'bssid' '02:CA:FF:EE:BA:BE'
|
||||
|
@ -15,6 +16,7 @@ config 'wifi-iface'
|
|||
|
||||
config 'wifi-iface'
|
||||
option 'device' 'wifi0'
|
||||
option 'network' 'mesh'
|
||||
option 'mode' 'ap'
|
||||
option 'ssid' 'oldenburg.freifunk.net'
|
||||
option 'encryption' 'none'
|
||||
|
|
|
@ -1,12 +1,29 @@
|
|||
# Put your custom commands here that should be executed once
|
||||
# the system init finished. By default this file does nothing.
|
||||
|
||||
toLower() {
|
||||
echo $1 | sed -e "s/A/a/g" -e "s/B/b/g" -e "s/C/c/g" -e "s/D/d/g" -e "s/E/e/g" -e "s/F/f/g"
|
||||
}
|
||||
|
||||
BRMAC=`ifconfig -a br-mesh | grep 'HWaddr' | awk '{ print $5}'`
|
||||
BRMAC=`toLower $BRMAC`
|
||||
WLMAC=`ip link | grep wifi0 -A1 | grep link | awk '{ print $2 }'`
|
||||
WLMAC=`toLower $WLMAC`
|
||||
|
||||
if [[ "$BRMAC" != "$WLMAC" ]]; then
|
||||
logger -s "Fixing wrong MAC on br-mesh"
|
||||
uci set network.mesh.macaddr=$WLMAC
|
||||
uci commit
|
||||
#wait before reboot to generate tinc certificates and to be able
|
||||
#to login over ssh bevore reboot in case of errors
|
||||
sleep 30
|
||||
reboot
|
||||
fi
|
||||
|
||||
|
||||
ifconfig br-mesh down
|
||||
ifconfig br-mesh up
|
||||
|
||||
ifdown lan
|
||||
ifup lan
|
||||
|
||||
rdate -s time.fu-berlin.de
|
||||
|
||||
chown root.root /etc/crontabs/root
|
||||
|
|
Loading…
Reference in New Issue