Bug 1294092 - Destination of log for resources managed by Pacemaker remote are not clear
Destination of log for resources managed by Pacemaker remote are not clear
Status: CLOSED NOTABUG
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: pacemaker (Show other bugs)
7.2
x86_64 Linux
unspecified Severity low
: rc
: ---
Assigned To: Ken Gaillot
cluster-qe@redhat.com
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-12-24 10:50 EST by Raoul Scarazzini
Modified: 2016-01-08 11:45 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-01-04 11:32:35 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Raoul Scarazzini 2015-12-24 10:50:49 EST
We are doing a lot of debugging on a pacemaker remote node, and we've noticed that not all the logs are stored, as we would expect, into the file /var/log/pacemaker.log.

For example, we added this to a resource agent code:

ocf_log info "Starting nova-compute with --verbose and --debug from ${NOVA_HOST}"

And we don't have any track of this lines into the log above. But we can reach it while looking into journalctl:

# journalctl |grep -i Starting\ nov
Dec 24 09:38:23 overcloud-novacompute-0.localdomain NovaCompute(nova-compute)[29800]: INFO: Starting nova-compute with --verbose and --debug from overcloud-novacompute-0

It might make sense to consolidate the logs in a single place, for usability purposes.
Comment 2 Ken Gaillot 2016-01-04 11:32:35 EST
The system log (via journalctl) is the "single place". By default, Pacemaker sends log messages of severity "notice" and greater to the system log, as well as all enabled log messages to pacemaker.log. This allows system administrators to look only at journalctl in most cases, with pacemaker.log available for reporting to us with bugs (or for advanced sysadmins to look at).

Resource agents are independent programs in their own packages, so they control their own logging, independently of Pacemaker. The ocf_log macro is quite complex to handle various log configurations.

If PCMK_debug is enabled for lrmd in /etc/sysconfig/pacemaker, ocf_log will send debug messages to pacemaker.log (or whatever is configured as the pacemaker detail log). So that might be what you're looking for.

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