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 A running program (attach) 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.
2. Attach to the first MPICH process in your workstation cluster by diving into it.
CLI: dattach executable pid
3. 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.
4. 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.
As an alternative, you can use the Group > Attach Subset command to predefine what TotalView should do. For more information, see Attaching to Processes Tips.
NOTE: If you are using TotalView Individual, all your MPI processes must execute on the computer on which you installed TotalView.
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.