|
- $Lang::tr{'lan'}:
- | $netsettings{'GREEN_ADDRESS'}
- |
+ if ( $netsettings{'GREEN_DEV'} ) { print <| $Lang::tr{'lan'}:
+ | $netsettings{'GREEN_ADDRESS'}
+ |
END
- if (`ifconfig | grep $netsettings{'GREEN_DEV'}`) { print "Online"; } else { print "Offline"; }
-print <
- $Lang::tr{'wireless'}:
- | $netsettings{'BLUE_ADDRESS'}
- |
+ if ( `cat /var/ipfire/proxy/advanced/settings | grep ^ENABLE=on` ) {
+ print "Proxy an";
+ if ( `cat /var/ipfire/proxy/advanced/settings | grep ^TRANSPARENT=on` ) { print " (transparent)"; }
+ } else { print "Proxy aus"; }
+ }
+ if ( $netsettings{'BLUE_DEV'} ) { print <$Lang::tr{'wireless'}:
+ | $netsettings{'BLUE_ADDRESS'}
+ |
END
- if (`ifconfig | grep $netsettings{'BLUE_DEV'}`) { print "Online"; } else { print "Offline"; }
-print <$Lang::tr{'dmz'}:
- | $netsettings{'ORANGE_ADDRESS'}
- |
+ if ( `cat /var/ipfire/proxy/advanced/settings | grep ^ENABLE_BLUE=on` ) {
+ print "Proxy an";
+ if ( `cat /var/ipfire/proxy/advanced/settings | grep ^TRANSPARENT_BLUE=on` ) { print " (transparent)"; }
+ } else { print "Proxy aus"; }
+ }
+ if (`ifconfig | grep $netsettings{'ORANGE_DEV'}`) { print <$Lang::tr{'dmz'}:
+ | $netsettings{'ORANGE_ADDRESS'}
+ | Online
END
- if (`ifconfig | grep $netsettings{'ORANGE_DEV'}`) { print "Online"; } else { print "Offline"; }
-print <$Lang::tr{'vpn'}:
- | N/A
- |
+ }
+ if ( `cat /var/ipfire/vpn/settings | grep ^ENABLED=on` ) {
+ my $ipsecip = `cat /var/ipfire/vpn/settings | grep ^VPN_IP= | cut -c 8-`;
+ print <$Lang::tr{'vpn'}:
+ | $ipsecip
+ | Online
END
- if (`ifconfig | grep ipsec0`) { print "Online"; } else { print "Offline"; }
-print <OpenVPN:
- | N/A
- |
+ }
+ if ( `cat /var/ipfire/ovpn/settings | grep ^ENABLED=on` ||
+ `cat /var/ipfire/ovpn/settings | grep ^ENABLED_BLUE=on` ||
+ `cat /var/ipfire/ovpn/settings | grep ^ENABLED_ORANGE=on`) {
+ my $ovpnip = `cat /var/ipfire/ovpn/settings | grep ^DOVPN_SUBNET= | cut -c 14- | sed -e 's\/\\/255.255.255.0\/\/'`;
+ print <OpenVPN:
+ | $ovpnip
+ | Online
END
- if (`ifconfig | grep tun0`) { print "Online"; } else { print "Offline"; }
+ }
+ if ( $netsettings{'DNS1'} ) { print <| DNS-Server: | $netsettings{'DNS1'}
+END
+ }
+ if ( $netsettings{'DNS2'} ) { print <$netsettings{'DNS2'}
+END
+ }
print <
END
@@ -215,38 +234,10 @@ foreach my $line (@df) {
}
}
-# Patches warning
-open(AV, "<${General::swroot}/patches/available") or die "Could not open available patches database ($!)";
-my @av = ;
-close(AV);
-open(PF, "<${General::swroot}/patches/installed") or die "Could not open installed patches file. ($!) ";
-while()
-{
- next if $_ =~ m/^#/;
- @temp = split(/\|/,$_);
- @av = grep(!/^$temp[0]/, @av);
-}
-close(PF);
-
-if ($#av != -1)
-{
- $warnmessage .= " $Lang::tr{'there are updates'}";
-}
-my $age = &General::age("/${General::swroot}/patches/available");
-if ($age =~ m/(\d{1,3})d/) {
- if ($1 >= 7) {
- $warnmessage .= "$Lang::tr{'updates is old1'} $age $Lang::tr{'updates is old2'}\n";
- }
-}
-
if ($warnmessage) {
- print "$warnmessage ";
+ print "";
}
-print "";
-system('/usr/bin/uptime');
-print " \n";
-
&Header::closebox();
&Header::closebigbox();
diff --git a/langs/de/cgi-bin/de.pl b/langs/de/cgi-bin/de.pl
index 07df2d9e8..c0738a748 100644
--- a/langs/de/cgi-bin/de.pl
+++ b/langs/de/cgi-bin/de.pl
@@ -1265,6 +1265,7 @@
'advproxy chgwebpwd ERROR' => 'F E H L E R :',
'advproxy update notification' => 'Update-Benachrichtigung!',
'advproxy update information' => 'Eine aktualisierte Version steht zum Download bereit. Besuchen Sie http://www.advproxy.net für weitere Informationen.',
+'linkq' => 'Verbindungsqualität',
);
diff --git a/langs/en/cgi-bin/en.pl b/langs/en/cgi-bin/en.pl
index bc8befa31..14f654008 100644
--- a/langs/en/cgi-bin/en.pl
+++ b/langs/en/cgi-bin/en.pl
@@ -1298,5 +1298,6 @@
'advproxy chgwebpwd ERROR' => 'E R R O R :',
'advproxy update notification' => 'Update notification!',
'advproxy update information' => 'There is an updated version available for download. Visit http://www.advproxy.net for more information.',
+'linkq' => 'Link Quality',
);
diff --git a/src/ROOTFILES.i386 b/src/ROOTFILES.i386
index 7dceacf88..1ddae00ff 100644
--- a/src/ROOTFILES.i386
+++ b/src/ROOTFILES.i386
@@ -26959,4 +26959,30 @@ etc/l7-protocols/protocols/zmaap.pat
#etc/l7-protocols/testing/regexp/regsub.c
#etc/l7-protocols/testing/test_match.sh
#etc/l7-protocols/testing/test_speed.c
-#etc/l7-protocols/testing/timeit.sh
\ No newline at end of file
+#etc/l7-protocols/testing/timeit.sh
+##
+## openvpn-2.0.7
+##
+usr/sbin/openvpn
+##
+## lzo-2.02
+##
+usr/include/lzo
+usr/include/lzo/lzo1.h
+usr/include/lzo/lzo1a.h
+usr/include/lzo/lzo1b.h
+usr/include/lzo/lzo1c.h
+usr/include/lzo/lzo1f.h
+usr/include/lzo/lzo1x.h
+usr/include/lzo/lzo1y.h
+usr/include/lzo/lzo1z.h
+usr/include/lzo/lzo2a.h
+usr/include/lzo/lzo_asm.h
+usr/include/lzo/lzoconf.h
+usr/include/lzo/lzodefs.h
+usr/include/lzo/lzoutil.h
+usr/lib/liblzo2.a
+usr/lib/liblzo2.la
+usr/lib/liblzo2.so
+usr/lib/liblzo2.so.2
+usr/lib/liblzo2.so.2.0.0
\ No newline at end of file
diff --git a/src/misc-progs/openvpnctrl.c b/src/misc-progs/openvpnctrl.c
index ab3242c41..96bc8d780 100644
--- a/src/misc-progs/openvpnctrl.c
+++ b/src/misc-progs/openvpnctrl.c
@@ -372,7 +372,7 @@ void startDaemon(void) {
fprintf(stderr, "OpenVPN is not enabled on any interface\n");
exit(1);
} else {
- snprintf(command, STRING_SIZE-1, "/usr/bin/openvpn --config /var/ipfire/ovpn/server.conf");
+ snprintf(command, STRING_SIZE-1, "/usr/sbin/openvpn --config /var/ipfire/ovpn/server.conf");
executeCommand(command);
}
}
diff --git a/src/scripts/makegraphs b/src/scripts/makegraphs
index 0639f2eba..42773338a 100644
--- a/src/scripts/makegraphs
+++ b/src/scripts/makegraphs
@@ -395,7 +395,7 @@ sub updatefwhitsgraph {
RRDs::graph ("$graphs/firewallhits-$interval-area.png",
"--start", "-1$interval", "-aPNG", "-i", "-z",
- "--alt-y-grid", "-w 500", "-h 200",
+ "--alt-y-grid", "-w 600", "-h 200",
"--color", "SHADEA#EAE9EE",
"--color", "SHADEB#EAE9EE",
"--color", "BACK#EAE9EE",
@@ -415,7 +415,7 @@ sub updatefwhitsgraph {
RRDs::graph ("$graphs/firewallhits-$interval-line.png",
"--start", "-1$interval", "-aPNG", "-i", "-z",
- "--alt-y-grid", "-w 500", "-h 200",
+ "--alt-y-grid", "-w 600", "-h 200",
"--color", "SHADEA#EAE9EE",
"--color", "SHADEB#EAE9EE",
"--color", "BACK#EAE9EE",
@@ -506,6 +506,73 @@ sub updatefwhitsdata {
print "Error in RRD::update for Firewallhits: $ERROR\n" if $ERROR;
}
+# Creates and updates a link quality database
+# -------------------------------------------
+sub updatelq {
+ if ( ! -e "$rrdlog/lq.rrd") {
+ RRDs::create ("$rrdlog/lq.rrd", "--step=300",
+ "DS:loss:GAUGE:600:0:100",
+ "DS:roundtrip:GAUGE:600:0:10000",
+ "RRA:AVERAGE:0.5:1:576",
+ "RRA:AVERAGE:0.5:6:672",
+ "RRA:AVERAGE:0.5:24:732",
+ "RRA:AVERAGE:0.5:144:1460");
+ $ERROR = RRDs::error;
+ print "Error in RRD::create for link: $ERROR\n" if $ERROR;
+ }
+ my $packetloss=0;
+ my $roundtrip=0;
+ my $test=0;
+# LQ_GATEWAY is the ip of your isp's public ip facing you
+ my $LQ_GATEWAY=`netstat -r | grep ^default | awk '{print \$2}'`;
+ my $NUMPINGS=10;
+ my $pingoutput = `ping -c $NUMPINGS -q $LQ_GATEWAY`;
+ chomp;
+ my @temp = split (/\/|\%|\s/, $pingoutput);
+ $packetloss = $temp[17];
+ $roundtrip = $temp[28];
+ RRDs::update ("$rrdlog/lq.rrd", "N:$packetloss:$roundtrip");
+ $ERROR = RRDs::error;
+ print "Error in RRD::update for line quality: $ERROR\n" if $ERROR;
+}
+
+sub updatelqgraph {
+ my $period = $_[0];
+ RRDs::graph ("$graphs/lq-$period.png",
+ "--start", "-1$period", "-aPNG", "-i", "-z",
+ "--alt-y-grid", "-w 600", "-h 100", "-l 0", "-r",
+ "-t $tr{'linkq'} ($tr{'graph per'} $tr{$period})",
+ "--lazy",
+ "--color", "SHADEA#EAE9EE",
+ "--color", "SHADEB#EAE9EE",
+ "--color", "BACK#EAE9EE",
+ "-v ms / pkts (% x10)",
+ "DEF:roundtrip=$rrdlog/lq.rrd:roundtrip:AVERAGE",
+ "DEF:loss=$rrdlog/lq.rrd:loss:AVERAGE",
+ "CDEF:roundavg=roundtrip,PREV(roundtrip),+,2,/",
+ "CDEF:loss10=loss,10,*",
+ "CDEF:r0=roundtrip,30,MIN",
+ "CDEF:r1=roundtrip,70,MIN",
+ "CDEF:r2=roundtrip,150,MIN",
+ "CDEF:r3=roundtrip,300,MIN",
+ "AREA:roundtrip#EE7000:>300 ms",
+ "AREA:r3#D88E1B:150-300 ms",
+ "AREA:r2#B9B63F:70-150 ms",
+ "AREA:r1#99E064:30-70 ms",
+ "AREA:r0#80FF80:<30 ms",
+ "AREA:loss10#800000:Packet loss (x10)",
+ "LINE1:roundtrip#707070:",
+ "GPRINT:roundtrip:MAX:$tr{'maximal'} $tr{'linkq'}\\:%3.2lf ms",
+ "GPRINT:roundtrip:AVERAGE:$tr{'average'} $tr{'linkq'}\\:%3.2lf ms",
+ "GPRINT:roundtrip:LAST:$tr{'current'} $tr{'linkq'}\\:%3.2lf ms\\j",
+ "GPRINT:loss:MAX:$tr{'maximal'} Loss\\:%3.2lf%%",
+ "GPRINT:loss:AVERAGE:$tr{'average'} Loss\\:%3.2lf%%",
+ "GPRINT:loss:LAST:$tr{'current'} Loss\\:%3.2lf%%\\j"
+ );
+ $ERROR = RRDs::error;
+ print "Error in RRD::graph for Link Quality: $ERROR\n" if $ERROR;
+}
+
## Update ipac logs
system ('/usr/sbin/fetchipac');
sleep 8;
@@ -569,6 +636,16 @@ updatefwhitsgraph ("week");
updatefwhitsgraph ("month");
updatefwhitsgraph ("year");
+###
+### Link Quality
+###
+updatelq();
+sleep 2;
+updatelqgraph("day");
+updatelqgraph("week");
+updatelqgraph("month");
+updatelqgraph("year");
+
###
### Network Graphs
###
| | | | | | | | | | |