From c73b44e358627551dfb4835c5eb0620078e6e9fc Mon Sep 17 00:00:00 2001 From: EUcancER Date: Thu, 27 Dec 2012 23:46:27 +0100 Subject: tinc_installer: fix ip_finder, Random, others --- retiolum/scripts/tinc_setup/new_install.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'retiolum') diff --git a/retiolum/scripts/tinc_setup/new_install.sh b/retiolum/scripts/tinc_setup/new_install.sh index b24a28a0..fadfa9f7 100755 --- a/retiolum/scripts/tinc_setup/new_install.sh +++ b/retiolum/scripts/tinc_setup/new_install.sh @@ -28,8 +28,8 @@ OS=${OS:-0} IP4=${IP4:-0} IP6=${IP6:-0} -RAND4=0 -RAND6=0 +RAND4=1 +RAND6=1 usage() { @@ -94,7 +94,7 @@ check_ip_valid6() #check if ip is taken function check_ip_taken() { - if grep -q -E "$1(#|/)" $TEMPDIR/hosts/* ;then + if grep -q -r -E "$1(#|/)" $TEMPDIR/hosts/ ;then return 1 else return 0 @@ -366,7 +366,7 @@ else echo '' >> tinc-up echo "addr4=\$(sed -n \"s|^ *Subnet *= *\\($SUBNET4[.][^ ]*\\) *$|\\1|p\" \$host)" >> tinc-up echo 'ifconfig $INTERFACE $addr4' >> tinc-up - echo "route add -net $FULLSUBNET netmask $RETARDEDMASK dev $INTERFACE " >> tinc-up + echo "route add -net $FULLSUBNET netmask $RETARDEDMASK dev \$INTERFACE " >> tinc-up fi #fix permissions -- cgit v1.2.3