Attaching to an MPICH Job
You can attach to an MPICH application even if it was not started under TotalView control. To attach to an MPICH application:
1. Start TotalView.
Select Attach to process on the Start a Debugging Session dialog. A list of processes running on the selected host displays in the Attach to Running Program(s) dialog.
1. Attach to the first MPICH process in your workstation cluster by diving into it.
dattach executable pid
2. On an IBM SP with the ch_mpi device, attach to the poe process that started your job. For details, see Starting TotalView on a PE Program.
Normally, the first MPICH process is the highest process with the correct program name in the process list. Other instances of the same executable can be:
*The p4 listener processes if MPICH was configured with ch_p4.
*Additional slave processes if MPICH was configured with ch_shmem or ch_lfshmem.
*Additional slave processes if MPICH was configured with ch_p4 and has a file that places multiple processes on the same computer.
1. After attaching to your program’s processes, a dialog launches where you can choose to also attach to slave MPICH processes. If you do, press Return or choose Yes. If you do not, choose No.
If you choose Yes, TotalView starts the server processes and acquires all MPICH processes.
Classic UI Only: As an alternative, use the Group > Attach Subset command to predefine what TotalView should do.
More information on attaching to processes
“Attaching to Processes Tips” in the Classic TotalView User Guide’s chapter “Debugging Strategies for Parallel Applications.”
In some situations, the processes you expect to see might not exist (for example, they may crash or exit). TotalView acquires all the processes it can and then warns you if it cannot attach to some of them. If you attempt to dive into a process that no longer exists (for example, using a message queue display), you are alerted that the process no longer exists.