Dump Job (DMPJOB)

The Dump Job (DMPJOB) command dumps the basic data structures, or specific calls of the current job or of the job being serviced as a result of the Start Service Job (STRSRVJOB) command. The information is dumped to a spooled printer file (QPSRVDMP) to be printed. If the user had specified SPOOL(*NO) on either the CHGPRTF command or the OVRPRTF command, then the output is not spooled but printed directly; and, if the printer is not available, then this command overrides the print job and spools the output. When the user specifies SPOOL(*NO) on one of the two commands above, the user must specify QPSRVDMP as the printer file. The dump includes formatted information about the specified programs, and dumps of specified operating system objects, system objects, and threads associated with the job.

Restrictions:

Parameters

Keyword Description Choices Notes
PGM Program to dump Single values: *ALL, *NONE
Other values (up to 10 repetitions): Element list
Optional
Element 1: Program Qualified object name
Qualifier 1: Program Name
Qualifier 2: Library Name, *ALL
Element 2: Call level Integer, *LAST, *FIRST, *ALL
JOBARA Job structure areas *ALL, *NONE Optional
ADROBJ Objects referenced by address *YES, *NO Optional
JOBTHD Job threads *YES, *NO, *THDSTK Optional
SLTTHD Thread ID to include Single values: *ALL, *SELECT
Other values (up to 20 repetitions): Hexadecimal value
Optional

Program to dump (PGM)

Specifies which program to dump. Up to 10 programs can be specified.

Single values

*ALL
All programs on the call stack are dumped.
*NONE
No programs are dumped. Only the lists of called and activated programs are dumped.

Element 1: Program

Qualifier 1: Program

name
Specify the name of the called program to dump.

Qualifier 2: Library

*ALL
Specifies that all libraries will be used to locate the specified program to dump. If *ALL is specified, a call level (element 3) cannot be specified.
name
Specify the name of the library to use to locate the program to dump.

Element 2: Call level

*LAST
The last (most recent) call with the program name specified is dumped.
*FIRST
The first (oldest) call with the program name specified is dumped.
*ALL
All calls with the program name specified are dumped.
integer-number
Specify the call level for a program with multiple calls in the stack. If *ALL is specified for the library name qualifier, the call level cannot be specified.

Job structure areas (JOBARA)

Specifies that the job structure areas of the process are dumped. Job structure areas consist of the following:

*ALL
The job structure areas are dumped.
*NONE
The job structure areas are not dumped.

Objects referenced by address (ADROBJ)

Specifies that objects addressed from the program storage of a program being dumped are also dumped. If *NONE is specified on the Program to dump (PGM) parameter, no addressed objects are dumped.

*YES
The addressed objects are dumped.
*NO
The addressed objects are not dumped.

Job threads (JOBTHD)

Specifies whether the list and information of the threads in the job is dumped.

Thread information consists of the following:

*YES
The thread list and information is dumped.
*NO
The thread list and information is not dumped.
*THDSTK
Only the thread call stack is dumped.

Thread ID to include (SLTTHD)

Specifies a list of up to twenty threads in the job whose information is to be included. If *NO is specified on the Job threads (JOBTHD) parameter, no threads are dumped.

Single values

*ALL
All threads are dumped.
*SELECT
A list of thread identifiers is shown from which the user can select up to twenty to be included.

Other values

thread-identifier
Specify the identifiers of up to twenty threads whose information is to be included.

Examples

Example 1: Dumping Programs

DMPJOB   PGM((QGPL/UPDATE *FIRST) (PAYROLL/MASTER *ALL))
         JOBARA(*ALL)  ADROBJ(*NO)

This command dumps the first occurrence of QGPL/UPDATE in the call stack and all occurrences of PAYROLL/MASTER. The job structure areas are dumped.

Example 2: Dumping Entire Job Structure

DMPJOB

This command dumps the entire job structure.

Example 3: Dumping Lists of Called and Activated Programs

DMPJOB   PGM(*NONE)  JOBARA(*NONE)

This command dumps the lists of programs called and activated.

Example 4: Dumping Job Thread List and Information

DMPJOB   PGM(*NONE)  JOBARA(*NONE)  JOBTHD(*YES)

This command dumps the list of the job's threads and their information.

Example 5: Dumping Only One Job Thread's Information

DMPJOB   PGM(*NONE)  JOBARA(*NONE)  JOBTHD(*YES)
         SLTTHD(00000001)

This command dumps thread identifier 00000001 and its information.

Example 6: Dumping Only the Thread Call Stack

DMPJOB   PGM(*NONE)  JOBTHD(*THDSTK)

This command dumps only the job's threads call stack.

Error messages

*ESCAPE Messages

CPF3546
Program parameters specified were not found.
CPF3560
Job being serviced not running.
CPF3563
Overflow value for file &1 in &2 too large.
CPF3585
Library name *ALL and call level cannot be used together.
CPF3909
Service command will not be processed.
CPF3918
Service request canceled.
CPF3925
Cannot open file &1.
CPF3935
Job being serviced ended during dump.
CPF3950
Error message &2 received for file &1. Request ended.
CPF3951
File &1 cannot be overridden by file name &2.
CPF3967
Dump not started because serviced job not running.
CPF3968
Dump not started because serviced job completed running.
CPF3969
Error during close of file &1. Output may not be complete.