[ start | index | login ]
start > knowledgebase > linux > java > jboss notes

jboss notes

Created by retep. Last edited by retep, 3 years and 100 days ago. Viewed 2,590 times. #2
[diff] [history] [edit] [rdf]
labels
attachments

JBoss Too Noisy?

JBoss logging too many DEBUG or INFO messages?

You'd think you could just change the log4j xml file in /usr/local/jboss/server/default/conf. But this has no effect.

Rather, in /usr/local/jboss/bin/run.sh there may be a:

  1. Setup JBoss sepecific properties
JAVA_OPTS="$JAVA_OPTS -Dprogram.name=$PROGNAME -Dlog4j.configuration=file:./log4j.properties"

Change properties to info from debug

That forces it to use the desired log4j configuration.

If that file is not there, try:

for file in $(find /usr/local/jboss -name log4j.xml); do
replace 'value="DEBUG"' 'value="ERROR"' -- $file
replace 'value="WARN"' 'value="ERROR"' -- $file
replace 'value="INFO"' 'value="ERROR"' -- $file
replace 'value="TRACE"' 'value="ERROR"' -- $file
done

And change the priority in the 'root' /usr/local/jboss/server/default/conf/log4j.xml element to:

<root>
      <priority value ="warn" />
      <appender-ref ref="CONSOLE"/>
      <appender-ref ref="FILE"/>
   </root>
no comments | post comment
Powered by snipsnap.org Found a mistake in a howto? Let us know via an email to p.blikibugs at rimuhosting com.