Qpid broker ignores log-enable option in its configuration file

Solution Verified - Updated -

Environment

Red Hat Enterprise MRG Messaging

Issue

  • specifying log-enable option in configuration file of qpid broker
  • specifying the option also on command line
  • the broker enables logging specified only on command line, while it ignores the option setting specified in configuration file

Resolution

Place all instances of log-enable option to just one configuration place - either all to command line, or all to configuration file.

Another possibility of no debugs printed out is wrong syntax of log-enable option provided. Please follow this KCS solution describing proper syntax.

Root Cause

Configuration options of qpid broker are taken from various configuration places (environmental variable, command line, configuration file) in a given precedence. If an option is set in more places, only the value from more preceded configuration place will be applied - see this solution for details. Note that the principle of configuration place precedence strictly applies even for the log-enable option, despite it can be specified multiple times.

Diagnostic Steps

Trivial reproducer:

echo "log-enable=trace+" > qpidd.conf
qpidd --config qpidd.conf --log-enable info+ 2>&1 | grep trace

No trace logs are printed out, despite properly configured in qpidd.conf.

After adding --log-enable trace+ to command line (or reversely after moving --log-enable info+ to qpidd.conf), trace logs appear.

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Comments