Installing IBM MQ server on Linux

You can install an IBM® MQ server on a 64-bit Linux® system.

Before you begin

  • If you install a copy of IBM MQ server for Linux using Electronic Software Download, obtained from Passport Advantage®, you need to uncompress the tar.gz file, and extract the installation files from the tar file, by using the following command:
    
      tar -xvf   WS_MQ_V8.0_TRIAL_FOR_Linux_ML.tar
    
    Important: You must use GNU tar (also known as gtar) to unpack any tar images.
  • CAUTION:
    The instructions in this topic do not apply to Linux Ubuntu or Linux on POWER® Systems - Little Endian . See Installing on Linux Ubuntu or Linux on POWER Systems - Little Endian for these platforms.
  • Before you start the installation procedure, ensure that you have completed the necessary steps outlined in Preparing the system.
  • If this installation is not the first installation on the system, you must ensure that the crtmqpkg command can write to a temporary location. By default, the crtmqpkg command will write to the /var/tmp directory. To use a different location, you can set the TMPDIR environment variable before you run the crtmqpkg command.
  • To run the crtmqpkg command used in this task, you must have the pax command or rpmbuild installed.
    Attention: pax and rpmbuild are not supplied as part of the product. You must obtain these from your Linux distribution supplier.

About this task

Install the server by using the RPM Package Manager installer to select the components you want to install. The components and package names are listed in Installing on Linux Ubuntu or Linux on POWER Systems - Little Endian.
Attention: If you install the packages using the wildcard character, that is, using the command rpm -ivh MQ*.rpm, you should install the packages in the following order:
  • MQSeriesRuntime
  • MQSeriesJRE
  • MQSeriesJava
  • MQSeriesServer
  • MQSeriesFTBase
  • MQSeriesFTAgent
  • MQSeriesFTService
  • MQSeriesFTLogger
  • MQSeriesFTTools
  • MQSeriesAMQP
  • MQSeriesAMS
  • MQSeriesXRService
  • MQSeriesExplorer
  • MQSeriesGSKit
  • MQSeriesClient
  • MQSeriesMan
  • MQSeriesMsg
  • MQSeriesSamples
  • MQSeriesSDK

Procedure

  1. Log in as root, or switch to the superuser by using the su command.
  2. Set your current directory to the location of the installation file. The location might be the mount point of the server DVD, a network location, or a local file system directory.
  3. Run the mqlicense.sh script.
    If you want to view a text-only version of the license, which can be read by a screen reader, type the following message:
    
    ./mqlicense.sh -text_only
    
    The license number is displayed.

    You must accept the license agreement before you can proceed with the installation.

  4. If this installation is not the first installation of IBM MQ on the system, you must run the crtmqpkg command to create a unique set of packages to install on the system. To run the crtmqpkg command to run on Linux, you must install the pax command and rpmbuild, which is located in the rpm-build package.
    Note: The crtmqpkg command is required only if this is not the first installation of IBM MQ on the system. If you have earlier versions of IBM MQ installed on your system, then installing the latest version works correctly if you install it in a different location.

    To run the crtmqpkg command on a Linux system:

    1. Enter the following command:
      
      ./crtmqpkg suffix
      
      where suffix is a name of your choosing that uniquely identifies the installation packages on the system. suffix is not the same as an installation name, although the names can be identical. suffix is limited to 16 characters in the ranges A-Z, a-z, and 0-9.
      Note: This command creates a full copy of the installation packages in a temporary directory. By default, the temporary directory is located at /var/tmp. You must ensure that the system has enough free space before you run this command. To use a different location, you can set the TMPDIR environment variable before you run the crtmqpkg command. For example:
      
      $ TMPDIR=/test ./crtmqpkg suffix
      
    2. Set your current directory to the location specified when the crtmqpkg command operation completes successfully.
      This directory is a subdirectory of the /var/tmp/mq_rpms directory, in which the unique set of packages is created. The packages have the suffix value contained within the file name. For example, using a suffix of "1":
      
      ./crtmqpkg 1
      
      means there is a subdirectory named /var/tmp/mq_rpms/1/x86_64.
      The packages are renamed according to the subdirectory, for example:
      
      From: MQSeriesRuntime-8.0.0-0.x86_64.rpm
      To: MQSeriesRuntime-1-8.0.0-0.x86_64.rpm
      
  5. Install IBM MQ.
    At a minimum, you must install the MQSeriesRuntime and the MQSeriesServer components.
    • To install to the default location, /opt/mqm, use the rpm -ivh command to install each component that you require.
      For example, to install the runtime and server components to the default location, use the following command:
      
      rpm -ivh MQSeriesRuntime-*.rpm MQSeriesServer-*.rpm
      
      To install all components to the default location use the following command:
      
      rpm -ivh MQSeries*.rpm
      
    • To install to a non-default location, use the rpm --prefix option. For each installation, all of the IBM MQ components that you require must be installed in the same location.

      The installation path specified must be either an empty directory, the root of an unused file system, or a path that does not exist. The length of the path is limited to 256 bytes and must not contain spaces.

      For example, enter the following installation path to install the runtime and server components to the /opt/customLocation directory on a 64-bit Linux system:
      
      rpm --prefix /opt/customLocation -ivh MQSeriesRuntime-*.rpm
      MQSeriesServer-*.rpm
      

What to do next

  • If you have chosen this installation to be the primary installation on the system, you must now set it as the primary installation. Enter the following command at the command prompt:
    
     MQ_INSTALLATION_PATH/bin/setmqinst -i -p MQ_INSTALLATION_PATH
    

    where MQ_INSTALLATION_PATH represents the directory where IBM MQ is installed.

    You can have only one primary installation on a system. If there is already a primary installation on the system, you must unset it before you can set another installation as the primary installation. For more information, see Changing the primary installation.

  • You might want to set up the environment to work with this installation. You can use the setmqenv or crtmqenv command to set various environment variables for a particular installation of IBM MQ . For more information, see setmqenv and crtmqenv.
  • If you want to confirm that the installation was successful, you can verify your installation. See Verifying a server installation, for more information.