RESET QMGR

Use the MQSC command RESET QMGR as part of our 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 Sources from which we can issue MQSC 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: None


RESET QMGR

RESET QMGR TYPE (ADVANCELOG)1(STATISTICS)1(PUBSUB)CHILD(child-name)PARENT(parent-name) TYPE (ARCHLOG)ARCHIVED( name?) 2 TYPE (REDUCELOG)REDUCE(AUTOONEMAX) 2CMDSCOPE(' ')3CMDSCOPE(qmgr-name)3CMDSCOPE(*)3Notes:

  • 1 Not valid on z/OS.
  • 2 Not valid on IBM i or z/OS.
  • 3 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 we need to disconnect from a child or parent queue manager with which the queue manager has become unable to communicate, we 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 we 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 Check that async commands for distributed networks have finished.
  • We 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.

We 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.

We should not need this command in normal circumstances. In general, when using automatic management of log files, we 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 we are using archive log management) as noticed by a high value for REUSESZ on the DISPLAY QMSTATUS command.

We 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.
        The extent name is, for example, S0000001.LOG or AMQA000001 on IBM i.

      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.
        The value can be one of the following:

          AUTO
          Reduce the log extents by an amount chosen by the queue manager.

          ONE
          Reduce the log extents by one extent, if possible.

          MAX
          Reduce the log extents by the maximum number possible.

      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 we 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.

Parent topic: MQSC commands