Installation guide
By default, the /etc/ini t. d /functi o ns script blocks core files from daemons called by
/etc/i ni t. d /rg manag er. For the daemon to create application cores, you must enable that
option. This procedure must be done on all cluster nodes that need an application core caught.
For creating a core file when the rgmanager daemon crashes, edit the /etc/sysco nfi g /cl uster
file. The DAEMONCOREFILELIMIT parameter allows the daemon to create core files if the process
crashes. There is a -w option that prevents the watchdog process from running. The watchdog
daemon is responsible for rebooting the cluster node if rg manag er crashes and, in some cases, if
the watchdog daemon is running then the core file will not be generated, so it must be disabled to
capture core files.
DAEMONCOREFILELIMIT="unlimited"
RGMGR_OPTS="-w"
Restart rgmanager to activate the new configuration options:
service rgmanager restart
Note
If cluster services are running on this cluster node, then it could leave the running services in
a bad state.
The core file will be written when it is generated from a crash of the rg manag er process.
ls /core*
The output should appear similar to the following:
/core.11926
Move or delete any old cores files under the / directory before restarting rg manag er to capture the
application core. The cluster node that experienced the rg manag er crash should be rebooted or
fenced after the core is captured to ensure that the watchdog process was not running.
9.4 .3. Recording a g d b Backt race Session
Once you have captured the core file, you can view its contents by using g d b, the GNU D ebugger.
To record a script session of g d b on the core file from the affected system, run the following:
$ script /tmp/gdb-rgmanager.txt
$ gdb /usr/sbin/rgmanager /tmp/rgmanager-.core.
This will start a g d b session, while scri pt records it to the appropriate text file. While in g d b, run the
following commands:
(gdb) thread apply all bt full
(gdb) quit
Press ctrl -D to stop the script session and save it to the text file.
Chapt er 9 . Diagnosing and Co rrect ing Problems in a Clust er
153