Create a multi-instance queue manager on Windows domain controllers
An example shows how to set up a multi-instance queue manager on Windows on domain controllers. The setup demonstrates the concepts involved, rather than being production scale. The example is based on Windows Server 2008. The steps might differ on other versions of Windows Server.
The configuration uses the concept of a mini-domain, or
The example configuration consists of three servers:domainlet; see Windows 2000, Windows Server 2003, and Windows Server 2008 cluster nodes as domain controllers. To add multi-instance queue managers to an existing domain, see Create a multi-instance queue manager on domain workstations or servers on Windows.
- sun
- A Windows Server 2008 server used as the first domain controller. It defines the wmq.example.com domain that contains sun, earth, and mars. It contains one instance of the multi-instance queue manager called QMGR.
- earth
- A Windows Server 2008 used as the second domain controller IBM MQ server. It contains the second instance of the multi-instance queue manager called QMGR.
- mars
- A Windows Server 2008 used as the file server.
Replace the italicized names in the example, with names of our choosing.
Before starting
- On Windows, we do not need to verify the file system that we plan to store queue manager data and log files on. The checking procedure, Verify shared file system behavior, is applicable to UNIX and Linux . On Windows, the checks are always successful.
- Do the steps in Create an Active Directory and DNS domain on Windows to create the first domain controller.
- Do the steps in Adding a second Windows domain controller to an example domain to add a second domain controller, install IBM MQ for Windows on both domain controllers, and verify the installations.
- Do the steps in Installing IBM MQ on Windows domain controllers in an example domain to install IBM MQ on the two domain controllers.
On a file server in the same domain create a share for the queue manager log and data directories. Next, create the first instance of a multi-instance queue manager that uses the file share on one of the domain controllers. Create the other instance on the other domain controller and finally verify the configuration. We can create the file share on a domain controller.
In the sample, sun is the first domain controller, earth the second, and mars is the file server.
Procedure
- Create the directories that are to contain the queue manager data and log files.
- On mars, type the command:
md c:\wmq\data, c:\wmq\logs
- Share the directories that are to contain the queue manager data and log files.
We must permit full control access to the domain local group mqm, and the user ID we use to create the queue manager. In the example, user IDs that are members of Domain Administrators have the authority to create queue managers.
The file share must be on a server that is in the same domain as the domain controllers. In the example, the server mars is in the same domain as the domain controllers.
- In Windows Explorer, right-click c:\wmq > Properties.
- Click the Security tab and click Advanced > Edit....
- Clear the check box for Include inheritable permissions from this object's owner. Click Copy in the Windows Security window.
- Select the lines for Users in the list of Permission entries and click Remove. Leave the lines for SYSTEM, Administrators, and CREATOR OWNER in the list of Permission entries.
- Click Add..., and type the name of the domain local group mqm. Click Check Names
- In response to a Windows Security window, Type the name and password of the Domain Administrator and click OK > OK.
- In the Permission Entry for wmq window, select Full Control in the list of Permissions.
- Click OK > Apply > OK > OK > OK
- Repeat steps e to h to add Domain Administrators.
- In Windows Explorer, right-click c:\wmq > Share....
- Click Advanced Sharing... and select the Share this folder check box. Leave the share name as wmq.
- Click Permissions > Add..., and type the name of the domain local group mqm ; Domain Administrators. Click Check Names.
- In response to a Windows Security window, Type the name and password of the Domain Administrator and click OK > OK.
- Create the queue manager QMGR on the first domain controller, sun.
crtmqm -sax -u SYSTEM.DEAD.LETTER.QUEUE -md \\mars\wmq\data -ld \\mars\wmq\logs QMGRThe system response:
IBM MQ queue manager created.
Directory '\\mars\wmq\data\QMGR' created.
The queue manager is associated with installation 'Installation1'.
Creating or replacing default objects for queue manager 'QMGR'.
Default objects statistics : 74 created. 0 replaced. 0 failed.
Completing setup.
Setup completed.
- Start the queue manager on sun, permitting a standby instance.
strmqm -x QMGRThe system response:
IBM MQ queue manager 'QMGR' starting.
The queue manager is associated with installation 'Installation1'.
5 log records accessed on queue manager 'QMGR' during the log
replay phase.
Log replay for queue manager 'QMGR' complete.
Transaction manager state recovered for queue manager 'QMGR'.
IBM MQ queue manager 'QMGR' started using V7.1.0.0.
- Create a second instance of QMGR on earth.
- Check the values of the Prefix and InstallationName parameters are correct for earth.
On sun, run the dspmqinf command:
dspmqinf QMGRThe system response:
QueueManager:
Name=QMGR
Directory=QMGR
Prefix=C:\ProgramData\IBM\MQ
DataPath=\\mars\wmq\data\QMGR
InstallationName=Installation1
- Copy the machine-readable form of the QueueManager stanza to the clipboard.
On sun run the dspmqinf command again, with the -o command parameter.
dspmqinf -o command QMGRThe system response:
addmqinf -s QueueManager -v Name=QMGR
-v Directory=QMGR -v Prefix="C:\ProgramData\IBM\MQ"
-v DataPath=\\mars\wmq\data\QMGR
- On earth run the addmqinf command from the clipboard to create an instance of the queue manager on earth.
Adjust the command, if necessary, to accommodate differences in the Prefix or InstallationName parameters.
addmqinf -s QueueManager -v Name= QMGR -v Directory= QMGR -v Prefix="C:\Program Files\IBM\WebSphere MQ" -v DataPath=\\mars\wmq\data\QMGR
IBM MQ configuration information added.
- Start the standby instance of the queue manager on earth.
strmqm -x QMGRThe system response:
IBM MQ queue manager 'QMGR' starting.
The queue manager is associated with installation 'Installation1'.
A standby instance of queue manager 'QMGR' has been started. The active
instance is running elsewhere.
Results
Verify that the queue manager switches over from sun to earth:
- On sun, run the command:
endmqm -i -r -s QMGRThe system response on sun:
IBM MQ queue manager 'QMGR' ending.
IBM MQ queue manager 'QMGR' ending.
IBM MQ queue manager 'QMGR' ending.
IBM MQ queue manager 'QMGR' ending.
IBM MQ queue manager 'QMGR' ending.
IBM MQ queue manager 'QMGR' ending.
IBM MQ queue manager 'QMGR' ended, permitting switchover to
a standby instance.
- On earth repeatedly type the command:
dspmqThe system responses:
QMNAME(QMGR) STATUS(Running as standby)
QMNAME(QMGR) STATUS(Running as standby)
QMNAME(QMGR) STATUS(Running)
What to do next
To verify a multi-instance queue manager using sample programs; see Verify the multi-instance queue manager on Windows.
- Adding a second Windows domain controller to an example domain
Add a second domain controller to the wmq.example.com domain to construct a Windows domain in which to run multi-instance queue managers on domain controllers and file servers.- Installing IBM MQ on Windows domain controllers in an example domain
Install and configure installations of IBM MQ on both domain controllers in the wmq.example.com domain.Parent topic: Windows domains and multi-instance queue managers
Related tasks
- Adding a second Windows domain controller to an example domain
- Installing IBM MQ on Windows domain controllers in an example domain
Related information