Fwd: Bug#688203: logwatch: http_rc_detail_rep-$code facility broken-as-designed
Willi Mann <[email protected]>
| Newsgroups | gmane.comp.log.logwatch.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi! Attached is a patch by Thorsten Glaser which fixes und documents a previously undocumented and non-working feature in the http service script. Please consider including it if you find it useful. WM -------- Original-Nachricht -------- Betreff: Bug#688203: logwatch: http_rc_detail_rep-$code facility broken-as-designed Weitersenden-Datum: Thu, 20 Sep 2012 09:15:02 +0000 Weitersenden-Von: Thorsten Glaser <[email protected]> Weitersenden-An: [email protected] Weitersenden-CC: Willi Mann <[email protected]> Datum: Thu, 20 Sep 2012 11:11:02 +0200 (CEST) Von: Thorsten Glaser <[email protected]> Antwort an: Thorsten Glaser <[email protected]>, [email protected] An: [email protected] Kopie (CC): [email protected] tags 688203 + patch thanks Hi, logwatch-7.4.0+svn20120502rev103/debian/patches/0007-fix-http_rc_detail_rep.patch attached, “should” fix the issue. bye, //mirabilos -- tarent solutions GmbH Rochusstraße 2-4, D-53123 Bonn • http://www.tarent.de/ Tel: +49 228 54881-393 • Fax: +49 228 54881-314 HRB 5168 (AG Bonn) • USt-ID (VAT): DE122264941 Geschäftsführer: Boris Esser, Sebastian Mancke ------------------------------------------------------------------------------ Got visibility? Most devs has no idea what their production app looks like. Find out how fast your code is with AppDynamics Lite. http://ad.doubleclick.net/clk;262219671;13503038;y? http://info.appdynamics.com/FreeJavaPerformanceDownload.html _______________________________________________ Logwatch-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/logwatch-devel
0007-fix-http_rc_detail_rep.patch
(text/x-diff, 1.9 KB)
Description: Unbreak and document http_rc_detail_rep The http_rc_detail_rep facility was never documented and does not work anyway because it uses a hyphen-minus in an environment variable which is not allowed syntax in many environments. Author: Thorsten Glaser <[email protected]> Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=688203 Last-Update: 2012-09-20 Index: logwatch-7.4.0+svn20120502rev103/conf/services/http.conf =================================================================== --- logwatch-7.4.0+svn20120502rev103.orig/conf/services/http.conf 2011-08-13 11:37:02.000000000 +0200 +++ logwatch-7.4.0+svn20120502rev103/conf/services/http.conf 2012-09-20 11:04:46.000000000 +0200 @@ -68,5 +68,13 @@ # To display all user accesses except "Unauthorized": # $HTTP_USER_DISPLAY = "$field{http_rc} != 401" +# To raise the needed level of detail for one or more specific +# error codes to display a summary instead of listing each +# occurrence, set a variable like the following ones: +# Raise 403 codes to detail level High +#$http_rc_detail_rep_403 = 10 +# Always show only summary for 404 codes +#$http_rc_detail_rep_404 = 20 + # vi: shiftwidth=3 tabstop=3 et Index: logwatch-7.4.0+svn20120502rev103/scripts/services/http =================================================================== --- logwatch-7.4.0+svn20120502rev103.orig/scripts/services/http 2012-05-04 20:42:37.000000000 +0200 +++ logwatch-7.4.0+svn20120502rev103/scripts/services/http 2012-09-20 11:04:47.000000000 +0200 @@ -735,7 +735,7 @@ if (not defined $StatusCode{$code}) { $StatusCode{$code} = "\(undefined\)"; } - if( ($ENV{"http_rc_detail_rep-$code"} || $detail) > $detail ) { + if( ($ENV{"http_rc_detail_rep_$code"} || $detail) > $detail ) { # only display summary for this code my $t = 0; my $u = 0;