mqsicreatedb command

Supported platforms

  • Windows

Purpose

The mqsicreatedb command creates a database and makes it accessible to the broker. The command: creates the database, creates an ODBC data source name, and if necessary, depending on the database type, creates and starts a Windows Service. The command creates at most a single instance of the Windows Service for each installation of a major product version. This command only supports the installed DB2 and Derby database engines.

Syntax

Parameters

DatabaseName
(Required) The name of the database you want to create. This must be the first parameter, and is case sensitive. Restrictions might be placed on the permissible length of the database name by the database engine. For restrictions on the character set that can be used, see Characters allowed in commands.
-i ServiceUserID
(Optional, Derby only) The user ID under which the DatabaseInstanceMgr service runs.

This can be specified in any valid username syntax:

  • domain\username
  • \\server\username
  • .\username
  • username

If you use the unqualified form for this user ID (username), the operating system searches for the user ID throughout its domain, starting with the local system. This search might take some time to complete.

The ServiceUserID specified must be a member of the local group mqbrkrs. The ID can be a direct or indirect member of the group. The ServiceUserID must also be authorized to access the home directory (where WebSphere Message Broker is installed).

This parameter is ignored if the database engine specified or defaulted for the command is DB2. A ServiceUserID is required for Derby, but only for the first invocation of this command. Subsequent invocations are associated with the existing Windows DatabaseInstanceMgr service that runs under the ServiceUserID specified on the earlier command

The security requirements for the ServiceUserID are detailed in Security requirements for Windows platforms.

-a ServicePassword
(Optional, Derby only) The password for the ServiceUserID. Specify this only if you specify ServiceUserID.
-p PortNumber
(Optional) The TCP/IP port number that this component will use on the local machine. If not specified, the default value 1527 is used.
-e dbType
(Optional) The database engine to be used to create and run the database. Currently supported values are DB2 and Derby. If you do not specify this option, and only one database engine is available, that engine is used. If both are available, the default engine is DB2.
-u dbUserID
(Optional, DB2 only) An additional user name that requires access to the database that is created by this command.

Authorization

The user ID used to invoke this command must have Administrator authority on the local system and be part of the mqbrkrs group.

Responses

This command returns the following responses:

  • BIP9801 No supported database product found
  • BIP9802 A database of name xxxx already exists
  • BIP9803 The requested database engine, xxxx, could not be found
  • BIP9805 A Cloudscape Network Server already running on port number
  • BIP9809 Creating database, this may take a while
  • BIP9811 The IBM MQSeries Brokers DatabaseInstanceMgr service already exists
  • BIP9812 The IBM Cloudscape Network Server failed to start
  • BIP9813 External process time out
  • BIP9815 The supplied database name xxxx is too many characters in length
  • BIP9816 Multiple database engines are installed. Defaulting to the DB2 database engine
  • BIP9817 The DB2 database engine was used to create the xxxx database
  • BIP9818 The IBM Cloudscape/Apache Derby database engine was used to create xxxx database

Examples

The following example sets up a database with the name brokerdb on port 1600:
mqsicreatedb brokerdb -p 1600
The following example sets up a Derby database with the name derbydb, using port number 1527:
mqsicreatedb derbydb -i wbrkuid -a wbrkpw -e Derby -p 1527