On Fri, 02 May 2008 14:26:58 +0200 (CEST)
 Petr Vorel <[EMAIL PROTECTED]> wrote:
Hello,

I'm trying to configure logging to syslog (with SyslogAppender) and NOT to console (stdout). Logging to syslog is fine, but I still get messages to stdout as well (for some reason I don't want to redirect it > /dev/null )

Does anyone have any idea what could cause logging to stdout as well?

Is something else manually configuring Log4j?  A rogue library?  Configuration is cumulative, so another call to configure() could very well be adding a ConsoleAppender to the root logger.

Jake



I'm running command (with -Dlog4j.debug - in case it helps to somebody to find something from it).

Thanks a lot for advise.

Pev



java -Dorg.quartz.properties=etc/quartz.properties -Dlog4j.debug -Dlog4j.configuration=etc/log4j.xml -cp .:lib/*:lib/quartz/* pser.Pser

log4j: Trying to find [etc/log4j.xml] using context classloader [EMAIL PROTECTED] log4j: Using URL [file:/home/petr/workspace/pkds/etc/log4j.xml] for automatic log4j configuration.
log4j: Preferred configurator class: org.apache.log4j.xml.DOMConfigurator
log4j: System property is :null
log4j: Standard DocumentBuilderFactory search succeded.
log4j: DocumentBuilderFactory is: com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl
log4j: debug attribute= "null".
log4j: Ignoring debug attribute.
log4j: reset attribute= "false".
log4j: Threshold ="null".
log4j: Retreiving an instance of org.apache.log4j.Logger.
log4j: Setting [org.quartz] additivity to [true].
log4j: Level value for org.quartz is [debug].
log4j: org.quartz level set to DEBUG
log4j: Class name: [org.apache.log4j.net.SyslogAppender]
log4j: Setting property [syslogHost] to [localhost].
log4j: Setting property [facility] to [LOCAL0].
log4j: Setting property [threshold] to [INFO].
log4j: Parsing layout of class: "org.apache.log4j.PatternLayout"
log4j: Setting property [conversionPattern] to [[%p] %l %d{dd MMM hh:mm:ss.SSS aa} %t [%c:%L]%n%m%n%n].
log4j: Adding appender named [syslog] to category [org.quartz].
log4j: Level value for root is [info].
log4j: root level set to INFO
log4j: Adding appender named [syslog] to category [root].
0 [main] INFO pser.Pser - reading data from Pser config file '/home/petr/workspace/pkds/etc/pser/pser.xml'
150 [main] INFO pser.Pser - 'port='15720'
152 [main] INFO pser.Pser - Pser.start(): running server, using port 15720, excepting connections 244 [main] INFO org.quartz.core.QuartzScheduler - Quartz Scheduler v.1.6.0 created. 247 [main] INFO org.quartz.plugins.management.ShutdownHookPlugin - Registering Quartz shutdown hook. 248 [main] INFO org.quartz.plugins.xml.JobInitializationPlugin - Registering Quartz Job Initialization Plug-in.
250 [main] INFO org.quartz.simpl.RAMJobStore - RAMJobStore initialized.
251 [main] INFO org.quartz.impl.StdSchedulerFactory - Quartz scheduler 'Sched1' initialized from specified file: 'etc/quartz.properties' 252 [main] INFO org.quartz.impl.StdSchedulerFactory - Quartz scheduler version: 1.6.0 282 [main] INFO org.quartz.xml.JobSchedulingDataProcessor - Parsing XML file: /home/petr/workspace/pkds/etc/jobs.xml with systemId: /home/petr/workspace/pkds/etc/jobs.xml validating: false validating schema: jar:file:/home/petr/workspace/pkds/lib/quartz-all-1.6.0.jar!/org/quartz/xml/job_scheduling_data_1_5.xsd 339 [main] INFO org.quartz.xml.JobSchedulingDataProcessor - Scheduling 1 parsed jobs. 340 [main] INFO org.quartz.xml.JobSchedulingDataProcessor - Adding job: testJobs.testJob1 343 [main] DEBUG org.quartz.xml.JobSchedulingDataProcessor - Scheduling job: testJobs.testJob1 with trigger: testJobs.testTrigger1 347 [main] INFO org.quartz.xml.JobSchedulingDataProcessor - 1 scheduled jobs. 348 [main] INFO org.quartz.core.QuartzScheduler - Scheduler Sched1_$_NON_CLUSTERED started.
349 [main] INFO pser.Pser - starting quartz, TODO: vypsat konfiguraci
3761 [Quartz Shutdown-Hook Sched1] INFO org.quartz.plugins.management.ShutdownHookPlugin - Shutting down Quartz... 3761 [Quartz Shutdown-Hook Sched1] INFO org.quartz.core.QuartzScheduler - Scheduler Sched1_$_NON_CLUSTERED shutting down. 3762 [Quartz Shutdown-Hook Sched1] INFO org.quartz.core.QuartzScheduler - Scheduler Sched1_$_NON_CLUSTERED paused. 3763 [Quartz Shutdown-Hook Sched1] INFO org.quartz.simpl.SimpleThreadPool - There are still 4 worker threads active. See javadoc runInThread(Runnable) for a possible explanation 3763 [Quartz Shutdown-Hook Sched1] DEBUG org.quartz.simpl.SimpleThreadPool - shutdown complete 3767 [Quartz Shutdown-Hook Sched1] INFO org.quartz.core.QuartzScheduler - Scheduler Sched1_$_NON_CLUSTERED shutdown complete.




My log4j configuration ---------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">

<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/";>

 <!-- syslog -->
 <appender name="syslog" class="org.apache.log4j.net.SyslogAppender">
   <param name="SyslogHost" value="localhost"/>
   <param name="Facility" value="LOCAL0"/>
   <param name="Threshold" value="INFO"/>
   <!--
    <param name="Threshold" value="FATAL"/>
   -->
   <layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="[%p] %l %d{dd MMM hh:mm:ss.SSS aa} %t [%c:%L]%n%m%n%n"/>
   </layout>
 </appender>


 <logger name="org.quartz">
   <level value="debug" />
   <appender-ref ref="syslog" />
 </logger>


 <root>
   <level value="info" />
   <appender-ref ref="syslog" />
 </root>

</log4j:configuration> My log4j configuration ---------------------------------
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to