Revision: 140
http://logwatch.svn.sourceforge.net/logwatch/?rev=140&view=rev
Author: opoplawski
Date: 2013-05-16 17:29:41 +0000 (Thu, 16 May 2013)
Log Message:
-----------
Update afpd for netatalk 2.2.0
Modified Paths:
--------------
scripts/services/afpd
Modified: scripts/services/afpd
===================================================================
--- scripts/services/afpd 2013-03-25 10:37:58 UTC (rev 139)
+++ scripts/services/afpd 2013-05-16 17:29:41 UTC (rev 140)
@@ -37,22 +37,45 @@
) {
# We don't care about these
}
- elsif ( ($Login) = ( $ThisLine =~ /login ([^ ]+)/) ) {
+ elsif ( ($Junk,$Login) = ( $ThisLine =~ /(login|Login by) ([^ ]+)$/) ) {
+ chomp($Login);
$UserLogin{$Login}++;
}
+ elsif ( $ThisLine =~ /started/ ) {
+ $Starts++;
+ }
+ elsif ( $ThisLine =~ /shutting down/ ) {
+ $Stops++;
+ }
+ elsif ( ($Read,$Write) = ( $ThisLine =~ /statistics: (\d+\.\d+) KB read, (\d+\.\d+) KB/) ) {
+ $TotalRead+=$Read;
+ $TotalWritten+=$Write;
+ }
else {
# Report any unmatched entries...
push @OtherList,$ThisLine;
}
}
-if (keys %UserLogin) {
+if (keys %UserLogin and $Detail) {
print "\nUsers Logged In:\n";
foreach $Line (keys %UserLogin) {
print " $Line : $UserLogin{$Line} Time(s)\n";
}
}
+if ($Starts and $Detail) {
+ print "\nNumber of server startups: $Starts\n";
+}
+
+if ($Stops and $Detail) {
+ print "\nNumber of server shutdowns: $Stops\n";
+}
+
+if (($TotalRead or $TotalWritten) and $Detail >= 5) {
+ print "\nTransfer Statistics: $TotalRead KB read, $TotalWritten KB written\n";
+}
+
if (($#OtherList >= 0) and (not $IgnoreUnmatched)) {
print "\n**Unmatched Entries**\n";
print @OtherList;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
------------------------------------------------------------------------------
AlienVault Unified Security Management (USM) platform delivers complete
security visibility with the essential security capabilities. Easily and
efficiently configure, manage, and operate all of your security controls
from a single console and one unified framework. Download a free trial.
http://p.sf.net/sfu/alienvault_d2d
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.