RESET QMGR
Use the MQSC command RESET QMGR as part of your backup and recovery procedures.
Use MQSC commands
For information on how we use MQSC commands, see Performing local administration tasks using MQSC commands.
We can issue this command from sources 2CR. For an explanation of the source symbols, see Use commands on z/OS®.
Use the TYPE(ARCHLOG) option to notify the queue manager that all log extents, up to the specified one, have been archived. If the log management type is not ARCHIVE, the command fails. Use the TYPE(REDUCELOG) option to request that the queue manager reduces the number of log extents, provided they are no longer required.
Synonym: NoneRESET QMGR
Notes:- 1 Not valid on z/OS.
- 2 Valid only on z/OS when the queue manager is a member of a queue-sharing group
Usage notes for RESET QMGR
- We can use this command to request that the queue manager starts writing to a new log extent, making the previous log extent available for backup. See Updating a backup queue manager. Alternatively, we can use this command to request that the queue manager ends the current statistics collection period and writes the collected statistics. We can also use this command to forcibly remove a publish/subscribe hierarchical connection for which this queue manager is nominated as either the parent or the child in the hierarchical connection.
- The queue manager might refuse a request to advance the recovery log, if advancing the recovery log would cause the queue manager to become short of space in the active log.
- You are unlikely to use RESET QMGR TYPE(PUBSUB) other than in exceptional circumstances. Typically the child queue manager uses ALTER QMGR PARENT(' ') to remove the hierarchical connection.
- When you need to disconnect from a child or parent queue manager with which the queue manager has become unable to communicate, you must issue the RESET QMGR TYPE (PUBSUB) command from a queue manager. When using this command, the remote queue manager is not informed of the canceled connection. It might, therefore, be necessary to issue the ALTER QMGR PARENT(' ') command at the remote queue manager. If the child queue manager is not manually disconnected, it is forcibly disconnected and the parent status is set to REFUSED.
- If you are resetting the parent relationship, issue the ALTER QMGR PARENT(' ') command, otherwise the queue manager attempts to re-establish the connection when the publish/subscribe capability of the queue manager is later enabled.
- Successful completion of the RESET QMGR TYPE(PUBSUB) command does not mean that the action completed. To check for true completion, see the RESET QMGR TYPE(PUBSUB) step in Checking that async commands for distributed networks have finished.
- You must specify one only of ADVANCELOG, STATISTICS, PUBSUB, ARCHLOG or REDUCELOG.
Usage notes for TYPE(ARCHLOG)
This option requires change authority on the queue manager object.
The command fails if the log extent is not recognized, or is the current log.
If, for some reason, the programmatic way that your enterprise notifies your log extents are archived is not working, and the disk is filling up with log extents, your administrator can use this command.
You need to determine yourself, the name to pass in from your archiving process, as to what has already been archived.
Usage notes for TYPE(REDUCELOG)
This option requires change authority on the queue manager object.
You should not need this command in normal circumstances. In general, when using automatic management of log files, you should leave it up to the queue manager to reduce the number of log extents as necessary.
For circular logging, we can use this option to remove inactive secondary log extents. A growth in secondary log extents is usually noticed by an increase in disk usage, often due to some specific issue in the past. Note: For circular logging the command might not be able reduce the log extents by the required number immediately. In that case, the command returns, and the reduction takes place asynchronously at some later point.For linear logging this can remove log extents that are not required for recovery (and have been archived if you are using archive log management) as noticed by a high value for REUSESZ on the DISPLAY QMSTATUS command.
You should run this command only after some specific event that has caused the number of log extents to be extraordinarily large.
The command blocks until the chosen number of extents have been deleted. Note that the command does not return the number of extents that have been removed, but a queue manager error log message is written, indicating what has taken place.
Parameter descriptions for RESET QMGR
- TYPE
-
- ADVANCELOG
- Requests that the queue manager starts writing to a new log extent, making the previous log extent available for backup. See Updating a backup queue manager. This command is accepted only if the queue manager is configured to use linear logging.
- ARCHLOG
-
- ARCHIVED ( name )
- Notifies the queue manager that this extent, and all logically earlier ones, have been archived.
- PUBSUB
- Requests that the queue manager cancels the indicated publish/subscribe hierarchical connection.
This value requires that one of the CHILD or PARENT attributes is specified:
- CHILD
- The name of the child queue manager for which the hierarchical connection is to be forcibly canceled. This attribute is used only with TYPE(PUBSUB). It cannot be used together with PARENT.
- PARENT
- The name of a parent queue manager for which the hierarchical connection is to be forcibly canceled. This attribute is used only with TYPE(PUBSUB). It cannot be used together with CHILD.
- REDUCELOG
-
- REDUCE
- Requests the queue manager to reduce the number of inactive or superfluous log extents and the way in which the log extents are reduced.
- STATISTICS
- Requests that the queue manager ends the current statistics collection period and writes the collected statistics.
- CMDSCOPE
-
This parameter applies to z/OS only and
specifies how the command runs when the queue manager is a member of a queue sharing group.
CMDSCOPE must be blank, or the local queue manager, if QSGDISP is set to GROUP.
- ' '
- The command runs on the queue manager on which it was entered. This value is the default value.
- qmgr-name
- The command runs on the queue manager you specify, providing the queue manager is active within
the queue sharing group.
We can specify a queue manager name other than the queue manager on which it was entered, only if you are using a shared queue environment and if the command server is enabled.
- *
- The command runs on the local queue manager and is also passed to every active queue manager in the queue sharing group. The effect of setting this value is the same as entering the command on every queue manager in the queue sharing group.