mqrestore: restore queue manager from back up

Restore a queue manager from a back up archive.

Purpose

You can use the mqrestore command to restore a queue manager, including all its log files and data, from a previously taken back up. The command cannot run if there is already a queue manager with the same name on the appliance. The archive file must be located in the backupfs location on the appliance that was specified by the createbackupfs command.

You can also use the mqrestore command to create an encrypted file system for an existing queue manager. You first take a back up of the queue manager and then restore it, specifying that the file system is to be encrypted.

Syntax

Read syntax diagramSkip visual syntax diagram mqrestore  -f filename -e-pPassphrase-ssize

Parameters

-f filename
Specifies the name of file containing the backup of the queue manager that you want to restore.
This parameter is required.
-e
Optionally specify that an encrypted file system is created for the restored queue manager.
Note: If you restore an encrypted back up without specifying the -e parameter, you are prompted to confirm that this is your intended action.
-p Passphrase
Optionally specify a passphrase for an encrypted file system. The passphrase can be between 1 and 512 characters. If you do not specify the passphrase here, you are prompted for it when you run the command. You should store a copy of the passphrase somewhere safe.
-s size
Optionally specify the size of the queue manager file system in GB. You can specify a value in MB by entering the value followed by the character M. For example, to specify a size of 3 GB, enter 3. To specify a size of 1024 MB, enter 1024M. You can use this parameter to downsize or increase the queue manager file system if required. The size defaults to the size of the file system when the queue manager backup was created.

Usage notes

  • This command must be run from the IBM® MQ administration mode. If the system is in the IBM MQ administration mode the prompt includes mqa(mqcli)#. To enter the IBM MQ administration mode, enter mqcli on the command line. To exit the IBM MQ administration mode, enter exit on the command line.
  • After restoration, the queue manager has the same name, configuration, and data as the original queue manager had when the archive was created. But any high availability or disaster recovery configuration is lost, the queue manager is restored as a stand-alone queue manager.
  • Only one queue manager can be restored at a time.

Examples

  • The following command restores the queue manager QM1 from the file QM1safeandsound.bak to an unencrypted file system. The size of the file system is the same as when the queue manager back up was created.
    mqrestore -f QM1safeandsound.bak
  • The following command restores the queue manager QM2 to an encrypted 1024 MB file system with the passphrase NothingButBlueSkies:
    mqrestore -f QM2safeandsound.bak -e -p NothingButBlueSkies -s 1024M

Related commands