From IBM® MQ 9.2.0 you can install IBM MQ on Linux®
Red Hat® by using the yum installer.
About this task
- Before you start the installation procedure, ensure that you have completed the necessary steps
outlined in Preparing the system on Linux.
- To install IBM MQ in a non default location, you must
run the crtmqpkg command. This command requires that the system has the following
commands installed:
- pax or rpmbuild
- createrepo
- yum-utils
These commands are not supplied as part of the product. You must get them from your Linux distribution supplier. The rpmbuild command is located in the rpm-build package.
Procedure
- Optional:
Log in as root, or with sufficient authority to run the following commands.
- Optional:
If your installation media is a downloadable installation image, obtained from Passport Advantage, you
must decompress the tar.gz file and extract the installation files from the tar
file:
- For example, if you download part number CC7K6ML, you decompress the file by using the following command:
- Similarly, extract the installation files from the tar file by using the following command:
tar -xvf CC7K6ML.tar
Important: You must use GNU tar (also known as gtar) to unpack any
tar images.
- Optional: If this is not the first installation on the system,
or if you want to install IBM MQ to a non default
location, run the crtmqpkg to create a unique set of packages to install on the
system:
./crtmqpkg suffix installationPath
where:
- suffix specifies 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.
- installationPath specifies the path where you want to install IBM MQ.
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 installationPath
- Set your current directory to the location of the installation packages. If you used the
crtmqpkg command, this directory is the location that is specified when the
crtmqpkg command operation completes successfully.
- Configure the yum repository:
A sample repository file is available in the MQServer directory of the
installation packages. You can use this sample to assist you in configuring the yum repository.
- Create or update the repository:
- If this is the first IBM MQ installation on the
system, create a file with the suffix
.repo, for example,
IBM_MQ.repo, in the /etc/yum.repos.d directory.
- If this is an additional IBM MQ installation on the
system, append the details of the additional installation to the appropriate
.repo
file in the /etc/yum.repos.d directory.
- Add the following contents to the repository file:
[IBM-MQ-v.r.m-architecture]
name=IBM MQ v.r.m architecture
baseurl=file:///installationFilesLocation
enabled=1
gpgcheck=0
- Replace the installationFilesLocation variable with the location of
the installation files.
- Replace the v.r.m variable with the version, release, and
modification number for the version of IBM MQ that you
want to install.
- Replace the architecture variable with the architecture of the
system you are installing on. This value is one of the following values:
- Optional:
Enable gpg key
verification. Replace
gpgcheck=0 with
gpgcheck=1 and
add an additional
gpgkey=<uri> line pointing to the
certificate provided, for example:
gpgcheck=1
gpgkey=file:///directory/to/ibm_mq_public.pgp
- Optional: If you appended contents to the repository file, clear the
repository cache by using the following command:
- Check that the IBM MQ repository is
available by using the following command:
- From IBM MQ 9.2.0, you have the
option of accepting the license before or after installing the product. To accept the license before
installing, run the mqlicense.sh script. The license agreement is displayed in
a language appropriate to your environment and you are prompted to accept or decline the terms of
the license:
- Install IBM MQ:
- To install all available components in the default location, use the following
command:
yum -y install MQSeries*
- To install all available components in a non default location, use the following
command:
yum -y install MQSeries*suffix*
where
suffix specifies the suffix that was chosen when you ran
crtmqpkg in step 3.
- To install a subset of components, specify the components that you want to install. Any
dependencies are automatically installed. To support the running of a queue manager, you must
install at least the MQSeriesRuntime and the MQSeriesServer components. For example, to install the
server component in the default location, use the following
command:
yum -y install MQSeriesServer*
- To install an older version of IBM MQ when
multiple versions are available in the repository file, use the following
command:
yum -y install MQSeries*-v.r.m-f
where
v.r.m-f specifies the version, release, modification, and fix pack level to
install.
Results
You installed IBM MQ on your Linux system.
What to do next
- If you chose to accept the license post-installation, do so now. See Accept the license after installing the product.
- If required, you can now set this installation to be 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 an IBM MQ installation on Linux, for more information.
- Only a user with a UID that is a member of the mqm group can issue
administration commands. If you want to enable users to issue administration commands, they must be
added to the mqm group. For more information, see Setting up the user and group on Linux and Authority to administer IBM MQ on AIX®, Linux, and Windows systems.