|
From: Phillip G. <pg...@co...> - 2006-09-06 14:00:26
|
Both loglevels need to be set to INFO:
wrapper.console.loglevel=3DNONE
must be:
wrapper.console.loglevel=3DINFO
Then the Log4J console appender output will appear in the wrapper.log file.
Regards,
Phillip
-----Original Message-----
From: wra...@li... on behalf of Alexander.Sch=
ul...@st...
Sent: Wed 9/6/2006 12:46
To: wra...@li...
Cc:=09
Subject: [Wrapper-user] how to get log4j output to wrapper logfile to use =
trigger?
Hi,
I'm using log4j to output log messages. Now the application is running
inside the wrapper on linux and I would like to use the trigger mechanism.
But the trigger is only locking for the stuff that is logged by the wrapper
itself.
I thought that if would let log4j do its output to STDOUT it would arrive
in the wrapper logfile, but nothing appears in the wrapper logfile.
Please, can someone tell me how to get the log4j-output to the wrapper log
so I can use the trigger?
Here is my configuration.
wrapper.conf:
...
# Trigger
wrapper.filter.trigger.1=3Djava.lang.OutOfMemoryError
wrapper.filter.action.1=3DRESTART
#********************************************************************
# Wrapper Logging Properties
#********************************************************************
# Format of output for the console. (See docs for formats)
wrapper.console.format=3DPM
# Log Level for console output. (See docs for log levels)
wrapper.console.loglevel=3DNONE
# Log file to use for wrapper output logging.
wrapper.logfile=3D/home/carlosad/bps/logs/wrapper.log
# Format of output for the log file. (See docs for formats)
wrapper.logfile.format=3DLPTM
# Log Level for log file output. (See docs for log levels)
wrapper.logfile.loglevel=3DINFO
# Maximum size that the log file will be allowed to grow to before
# the log is rolled. Size is specified in bytes. The default value
# of 0, disables log rolling. May abbreviate with the 'k' (kb) or
# 'm' (mb) suffix. For example: 10m =3D 10 megabytes.
wrapper.logfile.maxsize=3D5m
# Maximum number of rolled log files which will be allowed before old
# files are deleted. The default value of 0 implies no limit.
wrapper.logfile.maxfiles=3D1
# Log Level for sys/event log output. (See docs for log levels)
wrapper.syslog.loglevel=3DNONE
...
log4j.conf:
...
<!--
STDOUT
-->
<appender name=3D"STDOUT" class=3D"org.apache.log4j.ConsoleAppender=
">
<param name=3D"Target" value=3D"System.out" />
<layout class=3D"org.apache.log4j.PatternLayout">
<param name=3D"ConversionPattern" value=3D"%d %-5p
(%F:%L) # %m\n" />
</layout>
</appender>
<!--
STDERR
-->
<appender name=3D"STDERR" class=3D"org.apache.log4j.ConsoleAppender=
">
<param name=3D"Target" value=3D"System.err" />
<layout class=3D"org.apache.log4j.PatternLayout">
<param name=3D"ConversionPattern" value=3D"%d %-5p =
[%t]
%c %C{3} (%F:%L) # %m\n" />
</layout>
</appender>
...
<root>
<priority value=3D"warn" />
<appender-ref ref=3D"FILE_ERROR" />
<appender-ref ref=3D"STDOUT" />
<appender-ref ref=3D"STDERR" />
</root>
</log4j:configuration>
Thanks in advance
Alex
***************************************************************************=
************************
The information in this message is confidential and may be legally privile=
ged.=20
It is intended solely for the addressee. Access to this message by anyone e=
lse is=20
unauthorized. If you are not the intended recipient, any disclosure, copyin=
g, or=20
distribution of the message, or any action or omission taken by you in reli=
ance=20
on it is prohibited and may be unlawful. Please immediately contact the sen=
der if=20
you have received this message in error. This email does not constitute any=
=20
commitment from Cordys Holding BV or any of its subsidiaries except when=
=20
expressly agreed in a written agreement between the intended recipient and=
=20
Cordys Holding BV or its subsidiaries.
**************************************************************************=
*************************
|