]> git.ipfire.org Git - ipfire-2.x.git/commitdiff
Fix connscheduler reconnect
authorArne Fitzenreiter <arne_f@ipfire.org>
Thu, 9 Oct 2008 20:21:40 +0000 (22:21 +0200)
committerArne Fitzenreiter <arne_f@ipfire.org>
Thu, 9 Oct 2008 20:21:40 +0000 (22:21 +0200)
doc/packages-list.txt
src/initscripts/init.d/networking/red
src/scripts/connscheduler

index 8b70cd3defd2612778dad52a14ff076419e4f1fa..6866342a61d9ddea4ec842f61929675d0feded0b 100644 (file)
@@ -1,4 +1,4 @@
-== List of softwares used to build IPFire Version: 2.3-beta4 ==
+== List of softwares used to build IPFire Version: 2.3-test ==
 * Archive-Tar-1.29
 * Archive-Zip-1.16
 * BerkeleyDB-0.27
 * openswan-2.4.12
 * openswan-2.4.12-kmod
 * openvpn-2.0.9
+* p7zip_4.58
 * pam_mysql-0.7RC1
 * patch-2.5.4
 * pciutils-2.2.3
index 5efb5cab2d3662a7764d4d5cb1de48b1b88de7bc..b3347eb63185c7f38771857221edbdc16e08a171 100644 (file)
@@ -374,11 +374,7 @@ case "${1}" in
                                boot_mesg -n "LEASEINFO Test failed! - " ${WARNING}
                                boot_mesg "dhcpcd is not running!" ${WARNING}
                                echo_warning
-                               exit 1
                        fi
-                       
-                       ## Disable vnstat collection
-                       /usr/bin/vnstat -u -i ${DEVICE} -r --disable > /dev/null 2>&1
 
                elif [ "$TYPE" == "PPPOE" ]; then
                        boot_mesg "Bringing down the PPP interface ..."
@@ -401,10 +397,11 @@ case "${1}" in
                fi
                killall -w -s KILL /usr/sbin/pppd >/dev/null 2>&1
                killall -w -s KILL br2684ctl >/dev/null 2>&1
-               rm -f /var/ipfire/red/{active,device,dial-on-demand,dns1,dns2,local-ipaddress,remote-ipaddress,resolv.conf}
 
                ## Disable vnstat collection
                /usr/bin/vnstat -u -i ${DEVICE} -r --disable > /dev/null 2>&1
+
+               rm -f /var/ipfire/red/{active,device,dial-on-demand,dns1,dns2,local-ipaddress,remote-ipaddress,resolv.conf}
                exit 0;
                ;;
 esac
index 8c7f17f0f14f62ebcb4dbb4191e5d913379e90ad..f513cf45d42e8f717f93c814013c05981065a28a 100644 (file)
@@ -77,10 +77,13 @@ sub hangup
   }
 
   # now wait for active triggerfile and ppp daemon to disappear 
+  # wait maximum 60 seconds
+  my $counter = 60;
   sleep 1;
-  while ( -e "${General::swroot}/red/active" || -e '/var/run/ppp-ipfire.pid' ) 
+  while ( -e "${General::swroot}/red/active" || -e '/var/run/ppp-ipfire.pid' || $counter == 0 
   {
     sleep 1;
+    $counter--;
   }
 }
 
@@ -113,6 +116,15 @@ sub dial
 sub reconnect
 {
   &hangup() if ( -e "${General::swroot}/red/active" );
+  # now wait for active triggerfile and ppp daemon to disappear
+  # wait maximum 60 seconds
+  my $counter = 60;
+  sleep 1;
+  while ( -e "${General::swroot}/red/active" || -e '/var/run/ppp-ipfire.pid' || $counter == 0 ) 
+  {
+    sleep 1;
+    $counter--;
+  }
   &dial();
 }