The requirements in this section apply to Sun Cluster HA for WebSphere MQ only. You must meet these requirements before you proceed with your Sun Cluster HA for WebSphere MQ installation and configuration.
Your data service configuration might not be supported if you do not adhere to these requirements.
WebSphere MQ components and their dependencies —You can configure the Sun Cluster HA for WebSphere MQ data service to protect a WebSphere MQ instance and its respective components. These components and their dependencies are described.
Table 1–3 WebSphere MQ components and their dependencies (via -> symbol)
Component |
Description |
---|---|
Queue Manager(Mandatory) |
-> SUNW.HAStoragePlus resource The SUNW.HAStoragePlus resource manages the WebSphere MQ File System Mount points and ensures that WebSphere MQ is not started until these are mounted. |
Channel Initiator(Optional) |
-> Queue_Manager and Listener resources Dependency on the Listener is required only if runmqlsr is used instead of inetd. By default, a channel initiator is started by WebSphere MQ. However, if you want a different or another channel initiation queue, other than the default (SYSTEM.CHANNEL.INITQ), then you should deploy this component. |
Command Server (Optional) |
-> Queue_Manager and Listener resources Dependency on the Listener is required only if runmqlsr is used instead of inetd. Deploy this component if you want WebSphere MQ to process commands sent to the command queue. |
Listener (Optional) |
->Queue_Manager resource Deploy this component if you want a dedicated listener (runmqlsr) and will not use the inetd listener. |
Trigger Monitor (Optional) |
->Queue_Manager and Listener resources Dependency on the Listener is required only if runmqlsr is used instead of inetd. Deploy this component if you want a trigger monitor. |
For detailed information about these WebSphere MQ components, refer to IBM's WebSphere MQ Application Programming manual.
Each WebSphere MQ component has a configuration and registration file in /opt/SUNWscmqs/xxx/util, where xxx is a three-character abbreviation for the respective WebSphere MQ component. These files allow you to register the WebSphere MQ components with Sun Cluster.
Within these files, the appropriate dependencies have been applied.
# cd /opt/SUNWscmqs # # ls -l chi/util total 4 -rwxr-xr-x 1 root sys 720 Dec 20 14:44 chi_config -rwxr-xr-x 1 root sys 586 Dec 20 14:44 chi_register # # ls -l csv/util total 4 -rwxr-xr-x 1 root sys 645 Dec 20 14:44 csv_config -rwxr-xr-x 1 root sys 562 Dec 20 14:44 csv_register # # ls -l lsr/util total 4 -rwxr-xr-x 1 root sys 640 Dec 20 14:44 lsr_config -rwxr-xr-x 1 root sys 624 Dec 20 14:44 lsr_register # # ls -l mgr/util total 4 -rwxr-xr-x 1 root sys 603 Dec 20 14:44 mgr_config -rwxr-xr-x 1 root sys 515 Dec 20 14:44 mgr_register # # ls -l trm/util total 4 -rwxr-xr-x 1 root sys 717 Dec 20 14:44 trm_config -rwxr-xr-x 1 root sys 586 Dec 20 14:44 trm_register # # # more mgr/util/* :::::::::::::: mgr/util/mgr_config :::::::::::::: # # Copyright 2003 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # # This file will be sourced in by mgr_register and the parameters # listed below will be used. # # These parameters can be customized in (key=value) form # # RS - name of the resource for the application # RG - name of the resource group containing RS # QMGR - name of the Queue Manager # PORT - name of the Queue Manager port number # LH - name of the LogicalHostname SC resource # HAS_RS - name of the Queue Manager HAStoragePlus SC resource # CLEANUP - Cleanup IPC entries YES or NO (Default CLEANUP=YES) # # Under normal shutdown and startup WebSphere MQ manages it's # cleanup of IPC resources with the following fix packs. # # MQSeries v5.2 Fix Pack 07 (CSD07) # WebSphere MQ v5.3 Fix Pack 04 (CSD04) # # Please refer to APAR number IY38428. # # However, while running in a failover environment, the IPC keys # that get generated will be different between nodes. As a result # after a failover of a Queue Manager, some shared memory segments # can remain allocated on the node although not used. # # Although this does not cause WebSphere MQ a problem when starting # or stopping (with the above fix packs applied), it can deplete # the available swap space and in extreme situations a node may # run out of swap space. # # To resolve this issue, setting CLEANUP=YES will ensure that # IPC shared memory segments for WebSphere MQ are removed whenever # a Queue Manager is stopped. However IPC shared memory segments # are only removed under strict conditions, namely # # - The shared memory segment(s) are owned by # CREATOR=mqm and CGROUP=mqm # - The shared memory segment has no attached processes # - The CPID and LPID process ids are not running # - The shared memory removal is performed by userid mqm # # Setting CLEANUP=NO will not remove any shared memory segments. # # Setting CLEANUP=YES will cleanup shared memory segments under the # conditions described above. # RS= RG= QMGR= PORT= LH= HAS_RS= CLEANUP=YES :::::::::::::: mgr/util/mgr_register :::::::::::::: # # Copyright 2003 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # . `dirname $0`/mgr_config scrgadm -a -j $RS -g $RG -t SUNW.gds \ -x Start_command="/opt/SUNWscmqs/mgr/bin/start-qmgr \ -R $RS -G $RG -Q $QMGR -C $CLEANUP " \ -x Stop_command="/opt/SUNWscmqs/mgr/bin/stop-qmgr \ -R $RS -G $RG -Q $QMGR -C $CLEANUP " \ -x Probe_command="/opt/SUNWscmqs/mgr/bin/test-qmgr \ -R $RS -G $RG -Q $QMGR -C $CLEANUP " \ -y Port_list=$PORT/tcp -y Network_resources_used=$LH \ -x Stop_signal=9 \ -y Resource_dependencies=$HAS_RS # |
WebSphere MQ Manager protection—
WebSphere MQ is unable to determine whether a Queue Manager is already running on another node within Sun Cluster if Global File Systems are being used for the WebSphere MQ instance, that is, /global/mqm/qmgrs/<qmgr> and /global/mqm/log/<qmgr>.
Under normal conditions, the Sun Cluster HA for WebSphere MQ data service manages the startup and shutdown of the Queue Manager, regardless of which Cluster File System is being used (for example, FFS or GFS).
However, it is possible that someone could manually start the Queue Manager on another node within Sun Cluster if the WebSphere MQ instance is running on a Global File System.
This has been reported to IBM and a fix is being worked on.
To protect against this happening, two options are available.
Use Failover File Systems for the WebSphere MQ instance
This is the recommended approach because the WebSphere MQ instance files would be mounted only on one node at a time. With this configuration, WebSphere MQ is able to determine whether the Queue Manager is running.
Create a symbolic link for strmqm/endmqm to check-start (Provided script).
The script /opt/SUNWscmqs/mgr/bin/check-start provides a mechanism to prevent the WebSphere MQ Manager from being started or stopped.
The check-start script will verify that the WebSphere MQ Manager is being started or stopped by Sun Cluster and will report an error if an attempt is made to start or stop the WebSphere MQ Manager manually.
Example 1–4shows a manual attempt to start the WebSphere MQ Manager. The response was generated by the check-start script.
# strmqm qmgr1 # Request to run </usr/bin/strmqm qmgr1> within SC3.0 has been refused # |
This solution is required only if you require a Global File System for the WebSphere MQ instance. Example 1–5details the steps that you must take to achieve this.
# cd /opt/mqm/bin # # mv strmqm strmqm_sc3 # mv endmqm endmqm_sc3 # # ln -s /opt/SUNWscmqs/mgr/bin/check-start strmqm # ln -s /opt/SUNWscmqs/mgr/bin/check-start endmqm # |
Edit the /opt/SUNWscmqs/mgr/etc/config file and change the following entries for START_COMMAND and STOP_COMMAND. In this example we have chosen to add a suffix to the command names with _sc3. You can choose another name.
# cat /opt/SUNWscmqs/mgr/etc/config # Copyright 2003 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # # Usage: # DEBUG=<RESOURCE_NAME> or ALL # START_COMMAND=/opt/mqm/bin/<renamed_strmqm_program> # STOP_COMMAND=/opt/mqm/bin/<renamed_endmqm_program> # DEBUG= START_COMMAND=/opt/mqm/bin/strmqm_sc3 STOP_COMMAND=/opt/mqm/bin/endmqm_sc3 # |
The above steps need to be done on each node within the cluster that will host the Sun Cluster HA for WebSphere MQ data service. Do not perform this procedure until you have created your Queue Manager(s), because crtmqm will call strmqm and endmqm on its behalf.
If you implement this workaround, then you must back it out whenever you need to apply any maintenance to WebSphere MQ. Afterwards, you would need to reapply this workaround. The recommended approach is to use Failover File Systems for the WebSphere MQ instance, until a fix has been made to WebSphere MQ.