follow
To unobtrusively debug a live process or a live thread in a process, use the follow process command in XR EXEC modeSystem Admin EXEC mode.
follow process [pid | location node-id]
Syntax Description
pid |
Follows the process with the process ID (PID) specified for the pid argument. |
location node-id |
Follows the target process on the designated node. The node-id argument is expressed in the rack/ slot notation. |
Command Default
Entering the follow process command without any keyword displays the stack information of the live processes with all the threads, heap memory usage, and register values.
Command Modes
XR EXEC mode
System Admin EXEC mode
Command History
Release |
Modification |
---|---|
Release 5.0.0 |
This command was introduced. |
Usage Guidelines
Use this command to unintrusively debug a live process or a live thread in a process. This command is particularly useful for debugging deadlock and livelock conditions, for examining the contents of a memory location or a variable in a process to determine the cause of a corruption issue, or in investigating issues where a thread is stuck spinning in a loop. A livelock condition is one that occurs when two or more processes continually change their state in response to changes in the other processes.
The following actions can be specified with this command:
-
Follow all live threads of a given process or a given thread of a process and print stack trace in a format similar to core dump output.
-
Display register values and status information of the target process.
Take a snapshot of the execution path of a thread asynchronously to investigate performance-related issues by specifying a high number of iterations with a zero delay.
Examples
sysadmin-vm:0_RP0# follow process 1 location 0/RP0
Location : 0/RP0
************************************************************
2013-09-20 01:57:30
Text address Size Library name
--------------------------------------------
00007f4b8a66c000 48 r-x-- libnss_files-2.12.so
00007f4b8a879000 1444 r-x-- libc-2.12.so
00007f4b8abec000 48 r-x-- libpci.so
00007f4b8adf9000 32 r-x-- librt-2.12.so
00007f4b8b002000 248 r-x-- libdbus-1.so.3.4.0
00007f4b8b241000 96 r-x-- libpthread-2.12.so
00007f4b8b45e000 128 r-x-- ld-2.12.so
--------------------------------------------
#0 0x00007f4b8a955c83 in select+0x13 from /lib64/libc-2.12.so
#1 0x000000000041f974 in ?? () from /sbin/init
#2 0x0000000000404b9d in ?? () from /sbin/init
#3 0x00007f4b8a897cce in __libc_start_main+0xfe from /lib64/libc-2.12.so
#4 0x0000000000404659 in ?? () from /sbin/init