mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-23 01:12:57 +02:00
Fix connscheduler reconnect
This commit is contained in:
@@ -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
|
||||
@@ -231,6 +231,7 @@
|
||||
* 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
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user