Skip Menu |

This queue is for tickets about the Sys-Syslog CPAN distribution.

Report information
The Basics
Id: 77532
Status: resolved
Priority: 0/
Queue: Sys-Syslog

People
Owner: Nobody in particular
Requestors: mommens [...] textkernel.nl
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: possible bug
Date: Wed, 30 May 2012 11:31:06 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: François Mommens <mommens [...] textkernel.nl>
Hi, there seems to be a bug with the Sys::Syslog module when used through the Log::Dispatch::Syslog log4perl appender and the log4perl fatal() method. Sys::Syslog croaks at line 383 ("syslog: level must be given") and so no log line is produced. How to reproduce: perl script: use Log::Log4perl qw/ get_logger /; Log::Log4perl::init_and_watch("log4perl.conf", 30); my $logger = get_logger(); $logger->error('error'); $logger->fatal('fatal'); log4perl.conf: log4perl.appender.STDERR = Log::Log4perl::Appender::Screen log4perl.appender.STDERR.layout = PatternLayout log4perl.appender.STDERR.layout.ConversionPattern = %d{yyyy-MM-dd HH:mm:ss} %p %s [%P] %C(%L): %m%n log4perl.appender.STDERR.layout.cspec.s = sub { use File::Basename; return basename($0) } log4perl.appender.STDERR.stderr = 1 log4perl.appender.STDERR.utf8 = 1 log4perl.appender.Syslog = Log::Dispatch::Syslog log4perl.appender.Syslog.Threshold = INFO log4perl.appender.Syslog.ident = jobfeed_DE log4perl.appender.Syslog.layout = PatternLayout log4perl.appender.Syslog.layout.ConversionPattern = %p %s [%P] %c(%L): % m%n log4perl.appender.Syslog.layout.cspec.s = sub { use File::Basename; return basename($0) } log4perl.appender.Syslog.logopt = nodelay log4perl.rootLogger = DEBUG, STDERR, Syslog rsyslog configuration relevant part: $template outputTemplate,"%timestamp% %hostname% % syslogseverity-text:::uppercase% %syslogtag%%msg%\n" *.* /tmp/log;outputTemplate The error level log is produced, the fatal level not, as the Syslog module croaks. Environment: Syslog version: 0.29 distribution: Scientific linux 6.2 uname -a : Linux tk145 2.6.32-220.13.1.el6.i686 #1 SMP Tue Apr 17 15:16:12 CDT 2012 i686 i686 i386 GNU/Linux perl -v: This is perl 5, version 14, subversion 2 (v5.14.2) built for i686-linux-thread-multi (with 1 registered patch, see perl -V for more detail) Copyright 1987-2011, Larry Wall Binary build 1402 [295342] provided by ActiveState http://www.ActiveState.com uname -a: Thank you very much for your work. Best regards, François
Subject: Re: [rt.cpan.org #77532] possible bug
Date: Wed, 15 Aug 2012 03:50:38 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: Sébastien Aperghis-Tramoni <saper [...] cpan.org>
François Mommens wrote via RT: Show quoted text
> Hi,
Hello, Show quoted text
> there seems to be a bug with the Sys::Syslog module when used through > the Log::Dispatch::Syslog log4perl appender and the log4perl fatal() > method. Sys::Syslog croaks at line 383 ("syslog: level must be given") > and so no log line is produced. > > How to reproduce:[…]
Thank you for your detailed script and configuration. Show quoted text
> The error level log is produced, the fatal level not, as the Syslog > module croaks.
Using your script and configuration, I can't reproduce this bug: $ perl cpan-rt-77532.pl 2012-08-15 03:45:02 ERROR cpan-rt-77532.pl [9304] main(7): error 2012-08-15 03:45:02 FATAL cpan-rt-77532.pl [9304] main(8): fatal My environment: - perl v5.14.2 built for darwin-2level - Sys::Syslog 0.30 - Log::Dispatch 2.32 - Log::Log4perl 1.37 Maybe there was a bug in Log::Dispatch or Log::Log4perl? Did you try upgrading these modules to more recent version? Regards, -- Sébastien Aperghis-Tramoni Close the world, txEn eht nepO.
Subject: Re: [rt.cpan.org #77532] possible bug
Date: Sun, 26 Aug 2012 14:28:02 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: Sébastien Aperghis-Tramoni <saper [...] cpan.org>
The recent releases of Sys::Syslog fixed some bugs that prevented to specify the facility with syslog(). Maybe that was the cause of the problem you saw. I'll close this ticket for now, but feel free to reopen it if you happen to reproduce the problem you reported. -- Sébastien Aperghis-Tramoni Close the world, txEn eht nepO.