diff options
author | tv <tv@iiso> | 2011-11-10 01:39:57 +0100 |
---|---|---|
committer | tv <tv@iiso> | 2011-11-10 01:39:57 +0100 |
commit | a7c3985212df3b1c3599fe50d0542883d69ae1c6 (patch) | |
tree | 092718d74311850ba87eeb75ca50042868926b59 /retiolum/scripts/tinc_setup/tinc-up | |
parent | 87f92f68ffc436a81095ae8729008e309e0a3fd1 (diff) |
//retiolum tinc-up: first set up interface, then configure
Diffstat (limited to 'retiolum/scripts/tinc_setup/tinc-up')
-rwxr-xr-x | retiolum/scripts/tinc_setup/tinc-up | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/retiolum/scripts/tinc_setup/tinc-up b/retiolum/scripts/tinc_setup/tinc-up index 1a04706a..225f63a7 100755 --- a/retiolum/scripts/tinc_setup/tinc-up +++ b/retiolum/scripts/tinc_setup/tinc-up @@ -8,6 +8,8 @@ name=`sed -n 's|^ *Name *= *\([^ ]*\) *$|\1|p' $conf` host=$dirname/hosts/$name +ip link set $INTERFACE up + addr4=`sed -n 's|^ *Subnet *= *\(42[.][^ ]*\) *$|\1|p' $host` ip -4 addr add $addr4 dev $INTERFACE ip -4 route add 42.0.0.0/8 dev $INTERFACE @@ -15,5 +17,3 @@ ip -4 route add 42.0.0.0/8 dev $INTERFACE addr6=`sed -n 's|^ *Subnet *= *\(42[:][^ ]*\) *$|\1|p' $host` ip -6 addr add $addr6 dev $INTERFACE ip -6 route add 42::/16 dev $INTERFACE - -ip link set $INTERFACE up |