Repository : ssh://git@open-mesh.org/doc
On branches: backup-redmine/2017-09-28,master
commit d35afb94896db1df76465cc452b7fc080a1f46e5 Author: Sven Eckelmann sven@narfation.org Date: Sat Jul 29 12:09:45 2017 +0000
doc: open-mesh/rc.local
d35afb94896db1df76465cc452b7fc080a1f46e5 open-mesh/rc.local | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/open-mesh/rc.local b/open-mesh/rc.local index dce1f8fe..bcc80a2d 100644 --- a/open-mesh/rc.local +++ b/open-mesh/rc.local @@ -11,16 +11,16 @@ # # By default this script does nothing.
-MAC_PART="$(ip link show eth0 | awk '/ether/ {print $2}'| sed -e 's/.*://' -e 's/[\n\ ].*//'|awk '{print ("0x"$1)*1 }')" +MAC_PART="$(ip link show enp0s3 | awk '/ether/ {print $2}'| sed -e 's/.*://' -e 's/[\n\ ].*//'|awk '{print ("0x"$1)*1 }')" IP_PART="$(echo $MAC_PART|awk '{ print $1+50 }')" NODE_NR="$(echo $MAC_PART|awk '{ printf("%02d", $1) }')" -ip addr add 192.168.2.${IP_PART}/24 dev eth0 -ip link set up dev eth0 +ip addr add 192.168.2.${IP_PART}/24 dev enp0s3 +ip link set up dev enp0s3 hostname "node"$NODE_NR ip link set up dev lo
-insmod /host/batman-adv/batman-adv.ko -/host/batctl/batctl if add eth0 +insmod /host/batman-adv/build/net/batman-adv/batman-adv.ko +/host/batctl/batctl if add enp0s3 ip addr add 192.168.5.${IP_PART}/24 dev bat0 ip link set up dev bat0 #/host/batctl/batctl it 20000