mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-14 13:02:58 +02:00
connections.cgi hab ich gefixt - Die geht jetzt wieder praechtig! Und irgendwer (wohl mal wieder ich) hat in der lfs/iptables rumgewuetet :D Sowas aber auch... Tztz git-svn-id: http://svn.ipfire.org/svn/ipfire/trunk@426 ea5c0bd1-69bd-2848-81d8-4f18e57aeed8
34 lines
841 B
Perl
34 lines
841 B
Perl
#!/usr/bin/perl
|
|
#
|
|
# SmoothWall CGIs
|
|
#
|
|
# This code is distributed under the terms of the GPL
|
|
#
|
|
# (c) The SmoothWall Team
|
|
#
|
|
# $Id: ip-down,v 1.3.2.9 2005/01/26 12:23:26 riddles Exp $
|
|
#
|
|
|
|
use strict;
|
|
require 'CONFIG_ROOT/general-functions.pl';
|
|
|
|
&General::log("PPP has gone down on $ARGV[0]");
|
|
|
|
umask 022;
|
|
|
|
unlink "${General::swroot}/red/active";
|
|
system "/etc/rc.d/init.d/network red update";
|
|
|
|
# Beep when ppp goes up or down. Silence if 'nobeeps' file exists.
|
|
if ( ! -e "${General::swroot}/ppp/nobeeps") {
|
|
system('/usr/bin/beep','-l 75', '-f 880', '-n', '-l 75', '-f 440');
|
|
}
|
|
|
|
if ( -e "${General::swroot}/red/keepconnected") {
|
|
if ( system ('/bin/ps ax | /bin/grep -q "[r]c.connectioncheck reconnect"') ) {
|
|
system ('/etc/rc.d/init.d/connectioncheck reconnect &');
|
|
} else {
|
|
&General::log ('connectioncheck reconnect already running');
|
|
}
|
|
}
|