dmpmqcfg (dump queue manager configuration)

Use the dmpmqcfg command to dump the configuration of an IBM® MQ queue manager.


Use the dmpmqcfg command to dump the configuration of IBM MQ queue managers. If any default object has been edited, the -a option must be used if the dumped configuration will be used to restore the configuration.

When moving a queue manager from one operating system to another, you use dmpmqcfg to save the configuration information of the queue manager that you want to move, and then copy the object definitions across to the new queue manager that you create on the new operating system. You must take great care with copying the object definitions, because some manual modification of the definitions might be needed. For more information, see Moving a queue manager to a different operating system.

The dmpmqcfg utility dumps only subscriptions of type MQSUBTYPE_ADMIN, that is, only subscriptions that are created using the MQSC command DEFINE SUB or its PCF equivalent. The output from dmpmqcfg is a runmqsc command to enable the administration subscription to be re-created. Subscriptions that are created by applications using the MQSUB MQI call of type MQSUBTYPE_API are not part of the queue manager configuration, even if durable, and so are not dumped by dmpmqcfg. MQTT channels will only be returned for types -t all and -t mqttchl if the telemetry (MQXR) service is running. For instructions on how to start the telemetry service, see Administering MQ Telemetry.

From IBM MQ 8.0, the output of the dmpmqcfg is changed to ensure that password fields are commented out in the generated commands. This change brings the dmpmqcfg command in line with the DISPLAY commands, that show password fields as PASSWORD(********).

Note: The dmpmqcfg command does not make a backup of the Advanced Message Security policies. If you want to export the Advanced Message Security policies, ensure that you run dspmqspl with the -export flag. This command exports the policies for Advanced Message Security into a text file, which can be used for restoration purposes. For more information see dspmqspl (display security policy).
Attention: The inquiries used by dmpmqcfg inquire only QSGDISP(QMGR) definitions by default. You can inquire additional definitions by using the environment variable AMQ_DMPMQCFG_QSGDISP_DEFAULT. For more information about the values that you can set with this environment variable, see AMQ_DMPMQCFG_QSGDISP_DEFAULT.

[z/OS]For example, you could use AMQ_DMPMQCFG_QSGDISP_DEFAULT to query a z/OS® queue manager in a queue sharing group from an IBM MQ for Multiplatforms installation. Using the environment variable allows you to include shared objects that would otherwise not be included in the results.

Read syntax diagramSkip visual syntax diagram dmpmqcfg -? -cDEFINE CHANNEL String-cdefault -xallobjectauthrecchlauthsubpolicy-a-sSeqNumber-z-n*ObjectName-tallauthinfochannelclntconncomminfolstrmqttchlnamelist-omqsc1line2linesetmqautgrtmqmautsetmqspl-qSYSTEM.DEFAULT.MODEL.QUEUEReplyQueueName-rRmtQMgr-mQMgrName-wWaitTime -u UserId

Optional parameters

Inquire the usage message for dmpmqcfg.
Force a client mode connection. If the -c parameter is qualified with the option default, the default client connection process is used. If -c is omitted, the default is to attempt to connect to the queue manager first by using server bindings and then if this fails by using client bindings.

If the option is qualified with an MQSC DEFINE CHANNEL CHLTYPE(CLNTCONN) string then this is parsed and if successful, used to create a temporary connection to the queue manager.

-x [all|object|authrec|chlauth|sub|policy ]
Filter the definition procedure to show object definitions, authority records, channel authentication records, durable subscriptions or policy. The default value all is that all types are returned.

Note that when you specify an export type of policy, the security policies for the queue manager are reported in the configuration information dumped.

Return object definitions to show all attributes. The default is to return only attributes which differ from the defaults for the object type.
-s SeqNumber
Reset channel sequence number for sender, server and cluster sender channel types to the numeric value specified. The value SeqNumber must be in the range 1 - 999999999.
Activate silent mode in which warnings, such as those which appear when inquiring attributes from a queue manager of a higher command level are suppressed.
-n [*|ObjectName]
Filter the definitions produced by object or profile name, the object/profile name can contain a single asterisk. The * option can be placed only at the end of the entered filter string.
@class authority records are included in dmpmqcfg output regardless of the object or profile filter specified.
Attention: You cannot delete the @CLASS entries (the system is working as designed)
Choose a single type of object to export. The following table shows the possible values:
Table 1. Possible values for -t parameter
Value Description
all All object types
authinfo An authentication information object
channel or chl A channel
comminfo A communications information object
lstr or listener A listener
mqttchl An MQTT channel
namelist or nl A namelist
process or prcs A process
queue or q A queue
qmgr A queue manager
srvc or service A service
topic or top A topic
-o [mqsc|1line|2line|setmqaut|grtmqmaut|setmqspl]
The following table shows the possible values:
Table 2. Possible values for -o parameter options
Value Description
mqsc Multi-line MQSC that can be used as direct input to runmqsc
1line MQSC with all attributes on a single line for line diffing
2line MQSC with output on two lines. The first line is an MQSC command string and the second is a commented version with immutable values.
[AIX, Linux, Windows]setmqaut setmqaut statements for AIX®, Linux®, and Windows queue managers; valid only when -x authrec is specified.
[Linux]grtmqmaut Linux only; generates iSeries syntax for granting access to the objects.
setmqspl The security policies for the queue manager are reported in the format of setmqspl command lines. This format can be used to generate scripts to restore policy configuration to a queue manager.

Note that the setmqspl command lines produced by this format includes parameters (-m) that specify the queue manager from which the definition was backed up. This implies that the definitions need to be replayed against the same queue manager.

If you need to back up policy definitions from one queue manager, and restore them to a different queue manager, consider using the default MQSC format where the queue manager name is not explicitly specified.

The name of the reply-to queue used when getting configuration information.
The name of the remote queue manager/transmit queue when using queued mode. If this parameter is omitted the configuration for the directly connected queue manager (specified with the -m parameter) is dumped.
The name of the queue manager to connect to. If omitted the default queue manager name is used.
-w WaitTime
The time, in seconds, that dmpmqcfg waits for replies to its commands.

Any replies received after a timeout are discarded, but the MQSC commands still run.

The check for timeout is performed once for each command reply.

Specify a time in the range 1 through 999999; the default value is 60 seconds.

Timed-out failure is indicated by:
  • Nonzero return code to the calling shell or environment.
  • Error message to stdout or stderr.
-u UserId
The ID of the user authorized to dump the configuration of queue managers.


You must have MQZAO_OUTPUT (+put) authority to access the command input queue (SYSTEM.ADMIN.COMMAND.QUEUE) and MQZAO_DISPLAY (+dsp) authority to access the default model queue (SYSTEM.DEFAULT.MODEL.QUEUE), to be able to create a temporary dynamic queue if using the default reply queue.

You must also have MQZAO_CONNECT (+connect) and MQZAO_INQUIRE (+inq) authority for the queue manager, and MQZAO_DISPLAY (+dsp) authority for every object that is requested.

No authority is required on the object type (RQMNAME) to limit, or restrict the use of, the dmpmqcfg command to display details about any OBJTYPE(RQMNAME).

Return code

If a failure occurs dmpmqcfg returns an error code. Otherwise, the command outputs a footer, an example of which follows:

* Script ended on 2016-01-05   at 05.10.09
* Number of Inquiry commands issued: 14
* Number of Inquiry commands completed: 14
* Number of Inquiry responses processed: 273
* QueueManager count: 1
* Queue count: 55
* NameList count: 3
* Process count: 1
* Channel count: 10
* AuthInfo count: 4
* Listener count: 1
* Service count: 1
* CommInfo count: 1
* Topic count: 5
* Subscription count: 1
* ChlAuthRec count: 3
* Policy count: 1
* AuthRec count: 186
* Number of objects/records: 273


To make these examples work you need to ensure that your system is set up for remote MQSC operation. See Configuring queue managers for remote administration.

dumps all the configuration information from remote queue manager MYQMGR in MQSC format and creates an ad-hoc client connection to the queue manager using a client channel called SYSTEM.ADMIN.SVRCONN.
Note: You need to ensure that a server-connection channel with the same name exists.

dmpmqcfg -m LOCALQM -r MYQMGR
dumps all configuration information from remote queue manager MYQMGR, in MQSC format, connects initially to local queue manager LOCALQM, and sends inquiry messages through this local queue manager.
Note: You need to ensure that the local queue manager has a transmission queue named MYQMGR, with channel pairings defined in both directions, to send and receive replies between queue managers.