Bug 591762 - Configure SNMP4J to use Log4jLogFactory by default
Configure SNMP4J to use Log4jLogFactory by default
Product: RHQ Project
Classification: Other
Component: Alerts (Show other bugs)
All Linux
low Severity medium (vote)
: ---
: ---
Assigned To: RHQ Project Maintainer
Mike Foley
Depends On:
  Show dependency treegraph
Reported: 2010-05-12 22:57 EDT by James Livingston
Modified: 2016-02-21 19:54 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2014-05-29 14:05:09 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description James Livingston 2010-05-12 22:57:34 EDT
By default SNMP4J simply throws away it's logs, and it would be good if it sent them to Log4J by default so that they can be enabled just by editing jboss-log4j.xml. Currently you have to edit rhq-server.sh and restart JON to enable it.

To send SNMP4J logs to log4j, you can either add "-Dsnmp4j.LogFactory=org.snmp4j.log.Log4jLogFactory" to the RHQ java opts, or call LogFactory.setLogFactory(new org.snmp4j.log.Log4jLogFactory()) in code.

If this change is made, setting the org.snmp4j category to WARN (or ERROR) by default is probably a good idea.
Comment 1 John Mazzitelli 2011-02-17 12:37:27 EST
i think as a quick workaround, you can add that system property to rhq-server.properties
Comment 2 Jay Shaughnessy 2014-05-29 14:05:09 EDT
Assuming workaround is sufficient.

Note You need to log in before you can comment on or make changes to this bug.