Skip to main content

Sun Cluster Data Service for IBM WebSphere Message Broker Guide for Solaris OS - Middleware News

Installing and Configuring WebSphere Message Broker


Note – This deployment example is designed for a single node cluster. It is provided simply as a concise guide to help you if you need to refer to an installation and configuration of WebSphere Message Broker.
This deployment example is not meant to be a precise guide to install and configure WebSphere Message Broker.
If you need to install WebSphere Message Broker in any other configuration, refer to the general purpose procedures elsewhere in this manual.

The instructions with this deployment example assumes that you are using the WebSphere Message Broker v6 Solaris x86–64 platform and will configure WebSphere Message Broker on a ZFS highly available local file system.
The cluster resource group has already be configured to failover between two zones on a single node cluster.
This deployment examples assumes that you have completed the Deployment Example: Installing WebSphere MQ in Zones from the Sun Cluster Data Service for WebSphere MQ Guide.
The tasks you must perform to install and configure WebSphere Message Broker in the zones are as follows:
  • Example: Prepare the Cluster for WebSphere Message Broker
  • Example: Configure zones z1 and z2 for WebSphere Message Broker
  • Example: Install WebSphere Message Broker in the zones
  • Example: Verify WebSphere Message Broker
  • Example: Configure Cluster Resources for WebSphere Message Broker
  • Example: Enable the WebSphere Message Broker Software to Run in the Cluster
  • Example: Verify the Sun Cluster HA for WebSphere Message Broker Resource Group

Example: Prepare the Cluster for WebSphere Message Broker

Perform all steps within this example in the global zone.
  1. Install and configure the cluster as instructed in Sun Cluster Software Installation Guide for Solaris OS.
    Install the following cluster software components.
    • Sun Cluster core software
    • Sun Cluster HA for WebSphere Message Broker data service

    Note – This deployment example assumes that WebSphere MQ has been installed into zones z1 and z2 and that the Sun Cluster for WebSphere MQ data service has been installed and configured.
    This deployment example further assumes that the Deployment Example: Installing WebSphere MQ in Zones, from the Sun Cluster Data Service for WebSphere MQ Guide, was used to create the resource group wmq1-rg and zones z1 and z2.
    Within this deployment example a GDS resource is used to create and register a DB2 resource.

  2. Install and configure a Zettabyte file system.
    Create a ZFS pool.

    Note – The following zpool definitions represent a very basic configuration for deployment on a single node cluster.
    You should not consider this example for use within a productive deployment, instead it is a very basic configuration for testing or development purposes only.


    Vigor5# zpool create -m /ZFSwmb1 HAZpool3 c1t5d0
    

Example: Configure zones z1 and z2 for WebSphere Message Broker

  1. Import the ZFS pool into zone z1.
    Perform this step in the global zone only.

    Vigor5# zpool export -f HAZpool3
    Vigor5# zpool import -R /zones/z1/root HAZpool3
    
  2. Create some directories and a symbolic link for the WebSphere Message Broker and DB2 software.
    Perform this step in the global zone only.

    Vigor5# zlogin z1 mkdir /ZFSwmb1/mqsiuser /ZFSwmb1/db2user /ZFSwmb1/mqsi
    Vig0r5# zlogin z1 touch /ZFSwmb1/mqsiuser/.profile
    Vig0r5# zlogin z1 touch /ZFSwmb1/db2user/.profile
    Vigor5# zlogin z1 mkdir /opt/mqsi
    Vigor5# zlogin z2 mkdir /opt/mqsi
    Vigor5# zlogin z1 ln -s /ZFSwmb1/mqsi /var/mqsi
    Vigor5# zlogin z2 ln -s /ZFSwmb1/mqsi /var/mqsi
    
  3. Create the WebSphere Message Broker and DB2 userid in the zones.
    Perform this step from the global zone and repeat for zone z2.

    Vigor5# zlogin z1
    # groupadd -g 2000 mqbrkrs
    # useradd -u 2000 -G mqm,mqbrkrs -d /ZFSwmb1/mqsiuser -s /usr/bin/ksh mqsiuser
    # groupadd -g 3000 dba
    # useradd -u 3000 -G dba -d /ZFSwmb1/db2user -s /usr/bin/ksh db2user
    # passwd mqsiuser
    New Password: mqsiuser
    Re-enter new Password: mqsiuser
    # passwd db2user
    New Password: db2user
    Re-enter new Password: db2user
    # exit
    
  4. Setup file permissions in the ZFS pool.
    Perform this step in zone z1 only.

    Vigor5# zlogin z1
    # cd /ZFSwmb1
    # chown db2user:dba db2user
    # chown mqm:mqbrkrs mqsi
    # chown mqsiuser:mqbrkrs mqsiuser
    # exit
    

Example: Install WebSphere Message Broker in the zones


Caution – The steps within this procedure are not precise steps to install WebSphere Message Broker or DB2. Refer to the relevant IBM documentation for complete information.

  1. Mount the WebSphere Message Broker software in the zones.
    Perform this step in the global zone only.
    In this example, the WebSphere Message Broker software and DB2 software has been copied to node Vigor5 in directories /export/software/ibm/wmbv6 and /export/software/ibm/db2v8.

    Vigor5# zlogin z1 mkdir -p /var/tmp/software
    Vigor5# zlogin z2 mkdir -p /var/tmp/software
    Vigor5# mount -F lofs /export/software /zones/z1/root/var/tmp/software
    Vigor5# mount -F lofs /export/software /zones/z2/root/var/tmp/software
    
  2. Install the DB2 software in zone z1.
    Perform this step from the global zone for zone z1.

    Vigor5# zlogin z1
    # cat > /var/tmp/db2_response <<-eof eof="" install_type="TYPICAL" kbd="" lic_agreement="ACCEPT" prod="ENTERPRISE_SERVER_EDITION">
    # cd /var/tmp/software/ibm/db2v8
    # ./db2setup -r /var/tmp/db2_response
    
    Comment out chk_kernel_conf in /opt/IBM/db2/V8.1/instance/db2iutil as indicated by ->.
        # Check that kernel parameters are updated
     -> # chk_kernel_conf
        # Set the value of vars INSTHOME and INSTPGRP
        # and check their validity

    # vi /opt/IBM/db2/V8.1/instance/db2iutil
    # exit
    
  3. Install the WebSphere Message Broker software in zone z1.
    Perform this step from the global zone for zone z1 which can be performed at the same time you are installing the DB2 software.

    Vigor5# zlogin z1
    # cat > /var/tmp/install.opt <<-eof -p="" -w="" brokerfeature.active="true" configmanagerfeature.active="true" eof="" installlocation="/opt/IBM/mqsi/6.0" kbd="" setuptypes.selectedsetuptypeid="typical" transformationservicesfeature.active="true" unsfeature.active="true">
    # cd /var/tmp/software/ibm/wmbv6/messagebroker_runtime1
    # ./setupsolarisx86 -options /var/tmp/install.opt -silent
    # exit
    
  4. Relocate the ZFS pool to zone z2.
    Perform this step in the global zone.

    Vigor5# zpool export -f HAZpool3
    Vigor5# zpool import -R /zones/z2/root HAZpool3
    
  5. Install the DB2 software in zone z2.
    Perform this step from the global zone for zone z2.

    Vigor5# zlogin z2
    # cat > /var/tmp/db2_response <<-eof eof="" install_type="TYPICAL" kbd="" lic_agreement="ACCEPT" prod="ENTERPRISE_SERVER_EDITION">
    # cd /var/tmp/software/ibm/db2v8
    # ./db2setup -r /var/tmp/db2_response
    
    Comment out chk_kernel_conf in /opt/IBM/db2/V8.1/instance/db2iutil as indicated by ->.
        # Check that kernel parameters are updated
     -> # chk_kernel_conf
        # Set the value of vars INSTHOME and INSTPGRP
        # and check their validity

    # vi /opt/IBM/db2/V8.1/instance/db2iutil
    # exit
    
  6. Install the WebSphere Message Broker software in zone z2.
    Perform this step from the global zone for zone z2 which can be performed at the same time you are installing the DB2 software.

    Vigor5# zlogin z2
    # cat > /var/tmp/install.opt <<-eof -p="" -w="" brokerfeature.active="true" configmanagerfeature.active="true" eof="" installlocation="/opt/IBM/mqsi/6.0" kbd="" setuptypes.selectedsetuptypeid="typical" transformationservicesfeature.active="true" unsfeature.active="true">
    # cd /var/tmp/software/ibm/wmbv6/messagebroker_runtime1
    # ./setupsolarisx86 -options /var/tmp/install.opt -silent
    # exit
    
  7. Relocate the ZFS pool back to zone z1.
    Perform this step in the global zone.

    Vigor5# zpool export -f HAZpool3
    Vigor5# zpool import -R /zones/z1/root HAZpool3
    

Example: Verify WebSphere Message Broker

  1. Create the Broker database.
    Perform this step in the global zone for zone z1.

    Vigor5# zlogin z1
    # cd /opt/IBM/db2/V8.1/instance
    # ./db2icrt -u db2user db2user
    # su - db2user
    $ db2start
    $ db2 create database BROKERDB
    $ db2 connect to BROKERDB
    $ db2 bind ./sqllib/bnd/@db2cli.lst grant public CLIPKG 5
    $ db2 update database configuration for BROKERDB using dbheap 900
    $ chmod 644 /ZFSwmb1/db2user/sqllib/db2nodes.cfg
    $ cat > /ZFSwmb1/db2user/sqllib/db2nodes.cfg <<-eof 0="" db2user="" eof="" kbd="">
    $ chmod 444 /ZFSwmb1/db2user/sqllib/db2nodes.cfg
    $ exit
    
  2. Update /etc/hosts with db2user on both zones.
    Perform this step in zones z1 and z2.

    # vi /etc/hosts
    
    The following listing shows db2user that has been added to /etc/hosts on z1.
    127.0.0.1  localhost loghost z1 db2user
  3. Create the Broker, Configuration Manager and UserNameServer.
    Perform this step in zone z1 only.

    Note – The broker queue manager and broker database must be running before you perform this step.
    Ensure that DB2 is started and resource group wmq1-rg is online on Vigor5:z1.
    Deployment Example: Installing WebSphere MQ in Zones, from the Sun Cluster Data Service for WebSphere MQ Guide, was used to create the resource group wmq1-rg.


    # cat > /ZFSwmb1/mqsiuser/.profile <<-eof .="" bin="" db2profile="" db2user="" eof="" kbd="" mqsi="" mqsiprofile="" opt="" sqllib="" wmb1="">
    # su - mqsiuser
    $ mqsicreatebroker brk \
    > -i mqsiuser -a mqsiuser -q qmgr1 -n BROKERDB -u db2user -p db2user
    $ mqsicreateconfigmgr cmg \
    > -i mqsiuser -a mqsiuser -q qmgr1
    $ mqsicreateusernameserver \
    > -i mqsiuser -a mqsiuser -q qmgr1 
    $ exit
    
  4. Start the Broker, Configuration Manager and UserNameServer.
    Perform this step in zone z1.

    # su - mqsiuser
    $ mqsistart brk
    $ mqsistart cmg
    $ mqsistart UserNameServer
    
  5. Verify that the Broker, Configuration Manager and UserNameServer have been created and are running.
    Perform this step in zone z1.

    # su - mqsiuser
    $ mqsilist
    BIP8099I: ConfigMgr: cmg  -  qmgr1
    BIP8099I: UserNameServer: UserNameServer  -  qmgr1
    BIP8099I: Broker: brk  -  qmgr1
    
    BIP8071I: Successful command completion.
    $ exit
    # ptree mqsiuser
    2608  zsched
      15573 bipservice brk
        15574 bipbroker brk
          15590 biphttplistener brk
      15594 bipservice cmg
        15595 bipconfigmgr cmg
      15665 bipservice UserNameServer
        15666 bipuns UserNameServer
  6. Stop the Broker, Configuration Manager and UserNameServer.
    Perform this step in zone z1.

    # su - mqsiuser
    $ mqsistop -i brk
    $ mqsistop -i cmg
    $ mqsistop -i UserNameServer
    $ exit
    
  7. Stop the Broker database.
    Perform this step in zone z1.

    # su - db2user
    $ db2stop force
    $ exit
    # exit
    
  8. Failover the WebSphere MQ resource group to the other zone.
    Perform this step in the global zone.

    Vigor5# clrg switch -n Vigor5:z2 wmq1-rg
    
  9. Relocate the ZFS pool to the other zone.
    Perform this step in the global zone.

    Vigor5# zpool export -f HAZpool3
    Vigor5# zpool import -R /zones/z2/root HAZpool3
    
  10. Setup /etc/services and start the Broker database.
    Perform this step in zone z2.

    Note – The port list entries for db2user should be the same as those on zone z1.


    Vigor5# z2
    # cat >> /etc/services <<-eof 60000="" 60001="" 60002="" 60003="" db2_db2user="" db2_db2user_1="" db2_db2user_2="" db2_db2user_end="" eof="" kbd="" tcp="">
    # su - db2user
    $ db2start
    $ exit
    
  11. Start the Broker, Configuration Manager and UserNameServer.
    Perform this step in zone z2.

    # su - mqsiuser
    $ mqsistart brk
    $ mqsistart cmg
    $ mqsistart UserNameServer
    $ exit
    
  12. Verify that the Broker, Configuration Manager and UserNameServer are running.
    Perform this step in zone z2.

    # su - mqsiuser
    $ mqsilist
    BIP8099I: ConfigMgr: cmg  -  qmgr1
    BIP8099I: UserNameServer: UserNameServer  -  qmgr1
    BIP8099I: Broker: brk  -  qmgr1
    
    BIP8071I: Successful command completion.
    $ exit
    # ptree mqsiuser
    2614  zsched
      6658 bipservice brk
        6659 bipbroker brk
          6681 biphttplistener brk
      6674 bipservice cmg
        6675 bipconfigmgr cmg
      6691 bipservice UserNameServer
        6692 bipuns UserNameServer
  13. Stop the Broker, Configuration Manager and UserNameServer.
    Perform this step in zone z2.

    # su - mqsiuser
    $ mqsistop -i brk
    $ mqsistop -i cmg
    $ mqsistop -i UserNameServer
    $ exit
    
  14. Stop the Broker database.
    Perform this step in zone z2.

    # su - db2user
    $ db2stop force
    $ exit
    # exit
    
  15. Export the ZFS pool.
    Perform this step in the global zone.

    Vigor5# zpool export -f HAZpool3
    

Example: Configure Cluster Resources for WebSphere Message Broker

Perform all steps within this example in the global zone.
  1. Create the HAStoragePlus resource in the wmq1-rg resource group.

    Vigor5# clresource create -g wmq1-rg -t SUNW.HAStoragePlus \
    > -p Zpools=HAZpool3 wmq1-ZFSbrokerhas
    
    Alternatively, you can simply add HAZpool3 to the existing wmq1-ZFShas resource.
    Deployment Example: Installing WebSphere MQ in Zones, from the Sun Cluster Data Service for WebSphere MQ Guide, was used to create the wmq1-ZFShas resource..

    Vigor5# clresource set -p Zpools=HAZpool1,HAZpool2,HAZpool3 wmq1-ZFShas
    
  2. Enable the resource.
    This step is only required is you created the wmq1-ZFSbrokerhas resource.

    Vigor5# clresource enable wmq1-ZFSbrokerhas
    

Example: Enable the WebSphere Message Broker Software to Run in the Cluster

Perform all steps within this example in the global zone.
  1. Create and enable the DB2 cluster resource.

    Note – At the time of writing this deployment example, an IBM DB2 agent for Sun Cluster 3.2 was not available. Instead to provide high availability for DB2 the following GDS resource was used.


    Vigor5# z2
    # cat > /ZFSwmb1/db2user/ha-db2probe <<-eof -="" -c="" -i="" -p="" -s="" 0="" db2gcf="" db2user="" if="" su=""> /dev/null
    then
       rc=0
    else
       su - db2user -c "ipclean -a"
       rc=100
    fi
    return ${rc}
    EOF
    # chmod 755 /ZFSwmb1/db2user/ha-db2probe
    # exit
    Vigor5# clresource create -g wmq1-rg -t SUNW.gds \
    -p Start_command='/usr/bin/su - db2user -c "db2start"' \
    -p Stop_command='/usr/bin/su - db2user -c "db2stop force"' \
    -p Probe_command='/usr/bin/ksh /ZFSwmb1/db2user/ha-db2probe' \
    -p Network_aware=false wmq1-db2
    Vigor5# clresource enable wmq1-db2
    
  2. Create the Broker configuration file.
    Either cat the following into /var/tmp/brk_config or edit /opt/SUNWscmqi/sib/util/sib_config and execute /opt/SUNWscmqi/sib/util/sib_register.
    Within this step HAS_RS=wmq1-ZFShas is specified, if you created resource wmq1-ZFSbrokerhas you must specify HAS_RS=wmq1-ZFSbrokerhas.

    Vigor5# cat > /var/tmp/brk_config <<-eof broker="brk" has_rs="wmq1-ZFShas" lh="wmq1-lh" mqsi_id="mqsiuser" qmgr="qmgr1" qmgr_rs="wmq1-qmgr" rdbms_rs="" rg="wmq1-rg" rs="wmq1-brk" sc3_in="NONE" sc3_out="NONE" start_cmd="" stop_cmd="EOF</kbd">
    
  3. Register and enable the Broker resource.

    Vigor5# /opt/SUNWscmqi/sib/util/sib_register -f /var/tmp/brk_config
    Vigor5# clresource enable wmq1-brk
    
  4. Create the Configuration Manager configuration file.
    Either cat the following into /var/tmp/cmg_config or edit /opt/SUNWscmqi/sib/util/sib_config and execute /opt/SUNWscmqi/sib/util/sib_register.
    Within this step HAS_RS=wmq1-ZFShas is specified, if you created resource wmq1-ZFSbrokerhas you must specify HAS_RS=wmq1-ZFSbrokerhas.

    Vigor5# cat > /var/tmp/cmg_config <<-eof broker="cmg" has_rs="wmq1-ZFShas" lh="wmq1-lh" mqsi_id="mqsiuser" qmgr="qmgr1" qmgr_rs="wmq1-qmgr" rdbms_rs="" rg="wmq1-rg" rs="wmq1-cmg" sc3_in="NONE" sc3_out="NONE" start_cmd="" stop_cmd="EOF</kbd">
    
  5. Register and enable the Configuration Manager resource.

    Vigor5# /opt/SUNWscmqi/sib/util/sib_register -f /var/tmp/cmg_config
    Vigor5# clresource enable wmq1-cmg
    
  6. Create the UserNameServer configuration file.
    Either cat the following into /var/tmp/uns_config or edit /opt/SUNWscmqi/siu/util/siu_config and execute /opt/SUNWscmqi/siu/util/siu_register.
    Within this step HAS_RS=wmq1-ZFShas is specified, if you created resource wmq1-ZFSbrokerhas you must specify HAS_RS=wmq1-ZFSbrokerhas.

    Vigor5# cat > /var/tmp/uns_config <<-eof has_rs="wmq1-ZFShas" lh="wmq1-lh" mqsi_id="mqsiuser" qmgr="qmgr1" qmgr_rs="wmq1-qmgr" rg="wmq1-rg" rs="wmq1-uns" start_cmd="" stop_cmd="EOF</kbd">
    
  7. Register and enable the UserNameServer resource.

    Vigor5# /opt/SUNWscmqi/siu/util/siu_register -f /var/tmp/uns_config
    Vigor5# clresource enable wmq1-uns
    

Example: Verify the Sun Cluster HA for WebSphere Message Broker Resource Group

Perform this step in the global zone.
Switch the WebSphere MQ resource group between the two zones.

Vigor5# for node in Vigor5:z2 Vigor5:z1
do
   clrg switch -n $node wmq1-rg
   clrs status wmq1-brk
   clrs status wmq1-cmg
   clrs status wmq1-uns
   clrg status wmq1-rg
done

Comments

adsrerrapop

Popular posts from this blog

IBM Websphere MQ interview Questions Part 5

MQ Series: - It is an IBM web sphere product which is evolved in 1990’s. MQ series does transportation from one point to other. It is an EAI tool (Middle ware) VERSIONS:-5.0, 5.1, 5.3, 6.0, 7.0(new version). The currently using version is 6.2 Note: – MQ series supports more than 35+ operating systems. It is platform Independent. For every OS we have different MQ series software’s. But the functionality of MQ series Default path for installing MQ series is:- C: programfiles\BM\clipse\SDK30 C: programfiles\IBM\WebsphereMQ After installation it will create a group and user. Some middleware technologies are Tibco, SAP XI. MQ series deals with two things, they are OBJECTS, SERVICES. In OBJECTS we have • QUEUES • CHANNELS • PROCESS • AUTHENTICATION • QUERY MANAGER. In SERVICES we have LISTENERS. Objects: – objects are used to handle the transactions with the help of services. QUEUE MANAGER maintains all the objects and services. QUEUE: – it is a database structure

IBM Websphere MQ Reason code list / mq reason codes / websphere mq error codes / mq error messages

Reason code list ================= The following is a list of reason codes, in numeric order, providing detailed information to help you understand them, including: * An explanation of the circumstances that have caused the code to be raised * The associated completion code * Suggested programmer actions in response to the code * 0 (0000) (RC0): MQRC_NONE * 900 (0384) (RC900): MQRC_APPL_FIRST * 999 (03E7) (RC999): MQRC_APPL_LAST * 2001 (07D1) (RC2001): MQRC_ALIAS_BASE_Q_TYPE_ERROR * 2002 (07D2) (RC2002): MQRC_ALREADY_CONNECTED * 2003 (07D3) (RC2003): MQRC_BACKED_OUT * 2004 (07D4) (RC2004): MQRC_BUFFER_ERROR * 2005 (07D5) (RC2005): MQRC_BUFFER_LENGTH_ERROR * 2006 (07D6) (RC2006): MQRC_CHAR_ATTR_LENGTH_ERROR * 2007 (07D7) (RC2007): MQRC_CHAR_ATTRS_ERROR * 2008 (07D8) (RC2008): MQRC_CHAR_ATTRS_TOO_SHORT * 2009 (07D9) (RC2009): MQRC_CONNECTION_BROKEN * 2010 (07DA) (RC2010): MQRC_DATA_LENGTH_ERROR * 2011 (07DB) (RC2011): MQRC_DYNAMIC_Q_NAME_ERROR * 2012 (07DC) (RC201

IBM WebSphere MQ – Common install/uninstall issues for MQ Version on Windows - Middleware News

Creating a log file when you install or uninstall WebSphere MQ WebSphere MQ for Windows is installed using the Microsoft Installer (MSI). If you install the MQ server or client through launchpad , MQPARMS or setup.exe , then a log file is automatically generated in %temp% during installation. Alternatively you can supply parameters on the installation MSI command msiexec to generate a log file, or enable MSI logging system-wide (which generates MSI logs for all install and uninstall operations). If you uninstall through the Windows Add/Remove programs option, no log file is generated. You should either uninstall from the MSI command line and supply parameters to generate a log file, or enable MSI logging system-wide (which generates MSI logs for all install and uninstall operations). For details on how to enable MSI logging, see the following article in the WebSphere MQ product documentation: Advanced installation using msiexec For details on how to enable system-w