Guardian Procedure Calls Reference Manual

a file that the process had open with exclusive access or before you try to create a new process
with the same name. The best way to be sure that a process has terminated is to wait for the
process deletion message.
Stopping a process that has the Inspect or saveabend attribute set
If the process being stopped has either the Inspect attribute or the saveabend attribute set,
and if DMON exists, PROCESS_STOP_ returns error 0 but deletion of the process is delayed
until DMON approves it. In the case of an abnormal termination (ABEND), DMON creates
a saveabend file if the saveabend attribute is set.
In response to the PROCESS_STOP_ procedure, the operating system supplies a completion
code in the process deletion message and, for OSS processes, in the OSS process termination
status as follows:
If a process calls PROCESS_STOP_ on another process, the system supplies a completion
code value of 6.
If a process calls PROCESS_STOP_ with the STOP option on itself but does not supply a
completion code, the system supplies a completion code value of 0.
If a process calls PROCESS_STOP_ with the ABEND option on itself but does not supply
a completion code, the system supplies a completion code value of 5.
For a list of completion codes, see Appendix C: Completion Codes.
If PROCESS_STOP_ is issued by the backup process of a process pair, with a specifier
parameter value of 1, the intent is to stop the primary process and itself. However, if the
primary process is running in stop-mode 2, then only the backup process is stopped because
the primary process is running in stop-mode 2. If the primary process continues to run in
stop-mode 2 and tries to re-create the backup process, process-creation error 11,45 is returned.
This error also occurs when a primary process issues PROCESS_STOP_ with the specifier
parameter set to 1 to stop an unstoppable backup process and itself.
NetBatch Considerations
The PROCESS_STOP_ procedure supports NetBatch by:
returning the completion code information in the process deletion system message
returning the process processor time in the process deletion system message
sending a process deletion system message to the job ancestor (GMOM) of the job, as
well as to the mom and ancestor of the process, when any process in the job is terminated
Safeguard Considerations
For information on processes protected by Safeguard, see the Safeguard Reference Manual.
OSS Considerations
When an OSS process is stopped by the PROCESS_STOP_ procedure, either by calling the
procedure to stop itself or when some other process calls the procedure, the OSS caller process
receives a SIGCHLD signal and the OSS process termination status. See the wait(2) function
1126 Guardian Procedure Calls (P)