From: git@ipfire.org
To: ipfire-scm@lists.ipfire.org
Subject: [git.ipfire.org] IPFire 2.x development tree branch, next, updated. 78af2f67bba5900eb97989ed271b45a74448b457
Date: Thu, 17 Dec 2015 12:36:03 +0100 [thread overview]
Message-ID: <20151217113604.1726B2143E@argus.ipfire.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 2917 bytes --]
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "IPFire 2.x development tree".
The branch, next has been updated
via 78af2f67bba5900eb97989ed271b45a74448b457 (commit)
from b42a7ec1a663b356dde786cc7eeb1bb54ddcc662 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 78af2f67bba5900eb97989ed271b45a74448b457
Author: Alexander Marx <alexander.marx(a)ipfire.org>
Date: Thu Dec 17 11:31:30 2015 +0100
Squid-Accounting: Bugfix & clean up data
There was a Bug in the addon so that no data was displayed because of a
typo. Additionally the computeraccounts are now filtered out of
trafficdata collection.
Only Proxy/AD/LDAP Accounts and IP adresses are collected.
Signed-off-by: Alexander Marx <alexander.marx(a)ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer(a)ipfire.org>
-----------------------------------------------------------------------
Summary of changes:
lfs/squid-accounting | 2 +-
src/squid-accounting/acct.pl | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
Difference in files:
diff --git a/lfs/squid-accounting b/lfs/squid-accounting
index 2e45c24..ff78d36 100644
--- a/lfs/squid-accounting
+++ b/lfs/squid-accounting
@@ -15,7 +15,7 @@ THISAPP = squid-accounting-$(VER)
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(THISAPP)
PROG = squid-accounting
-PAK_VER = 8
+PAK_VER = 9
DEPS = "perl-DBI perl-DBD-SQLite perl-File-ReadBackwards perl-PDF-API2"
diff --git a/src/squid-accounting/acct.pl b/src/squid-accounting/acct.pl
index 68eb63c..e90d06e 100755
--- a/src/squid-accounting/acct.pl
+++ b/src/squid-accounting/acct.pl
@@ -100,7 +100,7 @@ if (-f $proxyenabled && $proxylog eq $Lang::tr{'running'}){
$dbh=&ACCT::connectdb;
my $m=sprintf("%d",(localtime((time-3600)))[4]+1);
&ACCT::logger($settings{'LOG'},"month before one hour $m, now is ".($mon+1)."\n");
- if ($m = ($mon+1) || $m == '12' && ($mon+1) == '1'){
+ if ($m < ($mon+1) || $m == '12' && ($mon+1) == '1'){
#Logrotate
my $year1=$year+1900;
system ("tar", "cfz", "/var/log/accounting-$m-$year1.tar.gz", "/var/log/accounting.log");
@@ -217,6 +217,7 @@ sub fill_db{
my $tim=time();
#Fill ACCT table with accounting information
foreach my $name (sort keys %counter){
+ next if (substr($name,-1,1) eq '$');
foreach my $bytes (keys %{ $counter{$name} }) {
$dbh->do("insert into ACCT (TIME_RUN,NAME,BYTES) values ('$tim','$name','$counter{$name}{$bytes}');");
}
hooks/post-receive
--
IPFire 2.x development tree
reply other threads:[~2015-12-17 11:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20151217113604.1726B2143E@argus.ipfire.org \
--to=git@ipfire.org \
--cc=ipfire-scm@lists.ipfire.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox