crtmqm (create queue manager)

Create a queue manager.

Purpose

You can use the crtmqm command to create a queue manager.

Syntax

Read syntax diagramSkip visual syntax diagram crtmqm -c Text-d DefaultTransmissionQueue-fe-fpPassphrase-fsFileSystemSize-h MaximumHandleLimit-icFilePath-iiFilePath-ivVARIABLE=VALUE[;VARIABLE=VALUE]-lf LogFilePages-lp LogPrimaryFiles-ls LogSecondaryFiles-p PortNumber-sx-sa-t IntervalValue-u DeadLetterQueue-x MaximumUncommittedMessages-fc SANvolume QMgrName

Parameters

QMgrName
Specifies the name of the queue manager that you want to create.
The queue manager name must be the last parameter that is specified in the command.
The name can contain up to 48 characters. The following characters can be used:

0-9 A-Z a-z . / _ %

The name of the queue manager must be unique on the IBM® MQ Appliance. If the queue manager connects to other queue managers, the queue manager names must be unique within that group of queue managers.
This parameter is required.
-c Text
Specifies descriptive text for this queue manager.
You can use up to 64 characters. If you include special characters, enclose the description in single quotation marks. The maximum number of characters is reduced if you are using a double-byte character set (DBCS).
The default value is all blanks.
-d DefaultTransmissionQueue
Specifies the name of the local transmission queue where remote messages are put if a transmission queue is not explicitly defined for their destination.
There is no default value.
-fe
Specifies that the file system for the queue manager is encrypted. You can optionally specify the encryption passphrase by using the -fp parameter, otherwise you are prompted for the passphrase when you run the command.
-fp Passphrase
Used in conjunction with the -fe parameter, optionally specifies the encryption passphrase. If you specify -fe but omit -fp you are prompted for the passphrase when you run the command. The passphrase can be between 1 and 512 characters. You should store a copy of the passphrase somewhere safe.
-fs FileSystemSize
Specifies that the queue manager is created with the file system size FileSystemSize. If you do not specify this argument, the file system size defaults to 64 GB.
FileSystemSize is a numeric value, which is specified in GB. You can specify a value in MB by entering the value followed by the character M. For example, to specify a FileSystemSize of 3 GB, enter 3. To specify a FileSystemSize of 1024 MB, enter 1024M.
For the appliance the minimum value is 128 MB.
The FileSystemSize is allocated from the available disk space. A disaster recovery or high availability queue manager requires twice the disk space of a stand-alone queue manager.
-h MaximumHandleLimit
Specifies the maximum number of handles that an application can open at the same time.
Specify a value in the range 1 - 999999999.
The default value is 256.
-ic FilePath
Automatic configuration of MQSC attributes.

Specify a location containing MQSC commands to be automatically applied to the queue manager on every queue manager restart. You can specify a filename, or a directory where each file with the .mqsc suffix is automatically processed. The file path must be under mqbackup:///. For information about this feature, see Automatic configuration from an MQSC script at startup in the IBM MQ documentation.

-ii FilePath
Automatic configuration of INI attributes.

Specify a location containing INI format information to be automatically applied as an override to the qm.ini file on every queue manager restart. You can specify a filename, or a directory where each file with the .ini suffix is automatically processed. The filepath must be under mqbackup:///. For information about this feature, see Automatic configuration of qm.ini at startup in the IBM MQ documentation.

-iv VARIABLE=VALUE[;VARIABLE=VALUE]
Configuration variable for use with automatic uniform clusters.

Specify a name and associated value for use as an insert when processing MQSC definitions. Currently only used for CONNAME fields in defining cluster receivers for automatic uniform clusters.

-lf LogFilePages
Specifies the number of log file pages to use for the log files.
The log data is held in a series of files called log files. The log file size is specified in units of 4 KB pages.
The default number of log file pages is 4096, giving a log file size of 16 MB. The minimum number of log file pages is 64 and the maximum is 65535.
-lp LogPrimaryFiles
Specifies the log files that are allocated when the queue manager is created.
The minimum number of primary log files you can have is 2 and the maximum is 510. The default is 3. The total number of primary and secondary log files must not exceed 511 and must not be less than 3.
You can change this value after the queue manager is created. However, the change is not effective until the queue manager is restarted.
-ls LogSecondaryFiles
Specifies the log files that are allocated when the primary files are exhausted.
The minimum number of secondary log files you can have is 2 and the maximum is 509. The default is 2. The total number of primary and secondary log files must not exceed 511 and must not be less than 3.
You can change this value after the queue manager is created. However, the change is not effective until the queue manager is restarted.
-p PortNumber
Create a managed TCP listener on the specified port.
Specify a valid port value to create a TCP listener object that uses the specified port. The new listener is called SYSTEM.LISTENER.TCP.1. This listener is under queue manager control, and is started and stopped along with the queue manager.
-sa
Automatic queue manager startup. The queue manager is configured to start automatically when the appliance restarts. This argument is mutually exclusive with -sx.
-sx
Specifies that the queue manager is a high availability (HA) queue manager.
The queue manager starts automatically as part of the HA group. This argument is mutually exclusive with -sa.
-t IntervalValue
Specifies the trigger time interval in milliseconds for all queues that are controlled by this queue manager.
That is, after the queue manager receives a trigger-generating message, triggering is suspended for the length of time that is specified by IntervalValue.
Specify a value in the range 0 - 999999999.
The default value is 999999999 milliseconds. This value effectively means that triggering is disabled after the first trigger message.
-u DeadLetterQueue
Specifies the name of the local queue that is to be used as the dead-letter (undelivered-message) queue.
The default is no dead-letter queue.
-x MaximumUncommittedMessages
Specifies the maximum number of uncommitted messages under any one sync point.
The uncommitted messages are the sum of the following messages:
  • The number of messages that can be retrieved from queues
  • The number of messages that can be put on queues
  • Any trigger messages that are generated within this unit of work
The limit that is specified does not apply to messages that are retrieved or put outside a sync point.
Specify a value in the range 1 - 999999999.
The default value is 10000 uncommitted messages.
-fc SANvolume
Specifies that the queue manager uses SAN storage. The LUN that the queue manager is associated with is identified by a previously-created volume object specified by SANvolume. This option is mutually exclusive with the -sx option, because SAN storage is not available to high availability queue managers. (SAN storage is available only on M2001 and M2000 appliances, it is not available on M2002 appliances.)

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 you create the queue manager, you can use the strmqm command to start the queue manager. A high availability queue manager is started automatically after creation, so you do not need to start it by using strmqm.
  • When a queue manager is created, the default and system objects are also created. These objects are listed in System and default objects in the IBM MQ documentation.
  • If you create a high availability queue manager with an encrypted file system, the passphrase is automatically shared with the second appliance in the HA group.
  • For more information about this command in IBM MQ, see ctrmqm in the IBM MQ documentation.

Examples

  • The following command creates a queue manager that is called QM1, with a description of example queue manager, and creates the system and default objects:
    
    crtmqm -c "example queue manager" QM1
    
  • The following command creates a queue manager that is called QM2. It creates the system and default objects, sets the trigger interval to 5000 milliseconds (5 seconds), and specifies SYSTEM.DEAD.LETTER.QUEUE as its dead-letter queue.
    
    crtmqm -t 5000 -u SYSTEM.DEAD.LETTER.QUEUE QM2
    
  • The following command creates a queue manager that is called QM3. The file system is encrypted using the passphrase Apples-grow-on-trees. The queue manager is created with a 512 MB file system:
    crtmqm -fs 512M -fe -fp Apples-grow-on-trees QM3

Related commands