]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/blobdiff - src/ppp/ip-down
Wieder einmal die Netzwerkscripts.
[people/teissler/ipfire-2.x.git] / src / ppp / ip-down
index 7b42b1de1ba60e6933fc67ba22b577698f1b9904..2373b900acee46dbe77e4c0897eb90a7f92cbce5 100644 (file)
@@ -1,33 +1,13 @@
-#!/usr/bin/perl
+#!/bin/sh
 #
-# 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]");
+rm -f /var/ipfire/red/active
 
-umask 022;
+run_subdir ${rc_base}/init.d/networking/red.down/
 
-unlink "${General::swroot}/red/active";
-system "/etc/rc.d/rc.updatered";
+[ -e "/var/ipfire/ppp/nobeeps" ] || /etc/rc.d/init.d/beep down
 
-# 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/rc.connectioncheck reconnect &');
-       } else {
-               &General::log ('rc.connectioncheck reconnect already running');
-       }
-}
+#[ -e "/var/ipfire/red/keepconnected" ] && \
+#      (ps ax | grep -q "connectioncheck reconnect") && \
+#      /etc/rc.d/init.d/connectioncheck reconnect &