setmqinst (set IBM MQ installation)

Set IBM MQ installations, on UNIX, Linux, and Windows.


Purpose

We can use the setmqinst command to change the installation description of an installation, to set or unset an installation as the primary installation, or to specify that the installation is a High Availability Replica and should be licensed accordingly. To change the primary installation, we must unset the current primary installation before we can set a new primary installation. This command updates information contained in the mqinst.ini file.

We can use the dspmqinst command to display the installations.

After unsetting the primary installation, the setmqinst command will not be available unless you specify the full path or have an appropriate installation directory on your PATH (or equivalent). The default path in a system standard location will have been deleted.

On UNIX platforms we should not assume that the current directory is in the path. If we are in /opt/mqm/bin and want to run, for example, /opt/mqm/bin/dspmqver we need to enter "/opt/mqm/bin/dspmqver" or "./dspmqver".

File mqinst.ini contains information about all IBM MQ installations on a system. For more information about mqinst.ini, see Installation configuration file, mqinst.ini.

On UNIX or Linux systems, we must run this command as root. On Windows systems, we must run this command as a member of the Administrators group. The command does not have to be run from the installation we are modifying.


Syntax

setmqinst Action Installation setmqinst Licensing Action-i-x-dDescriptiveTextInstallation-pInstallationPath-nInstallationName-nInstallationName-pInstallationPathLicensing -l license -e y|yes|n|no


Parameters

    -d DescriptiveText
    Text that describes the installation.

    The text can be up to 64 single-byte characters, or 32 double-byte characters. The default value is all blanks. We must use double quotation marks around the text if it contains spaces.

    -i
    Set this installation as the primary installation.

    -x
    Unset this installation as the primary installation.

    -n InstallationName
    The name of the installation to modify.

    -p InstallationPath
    The path of the installation to modify, for example, opt/mqm. We must use double quotation marks around the path if it contains spaces.

    -l license -e y|yes|n|no
    Specify that this installation is a High Availability Replica and should be licensed accordingly by setting license to hareplica. This installation type is picked up automatically by ILMT after you have identified the installation as a High Availability Replica. See IBM MQ license information. This entitlement can only be set if an applicable component is installed and a mutually exclusive tag, such as IBM MQ Advanced for Developers, is not present.


Return codes

Return code Description
0 Entry set without error
36 Invalid arguments supplied
37 Descriptive text was in error
44 Entry does not exist
59 Invalid installation specified
71 Unexpected error
89 ini file error
96 Could not lock ini file
98 Insufficient authority to access ini file
131 Resource problem


Examples

  1. This command sets the installation with the name of myInstallation as the primary installation:
    setmqinst -i -n myInstallation
    
  2. This command sets the installation with an installation path of /opt/myInstallation as the primary installation:
    setmqinst -i -p /opt/myInstallation
    
  3. This command unsets the installation named myInstallation as the primary installation:
    setmqinst -x -n myInstallation
    
  4. This command unsets the installation with an installation path of /opt/myInstallation as the primary installation:
    setmqinst -x -p /opt/myInstallation
    
  5. This command sets the descriptive text for the installation named myInstallation:
    setmqinst -d "My installation" -n myInstallation
    
    The descriptive text is enclosed in quotation marks as it contains spaces.
  6. This command specifies that the installation is a High Availability Replica:
    setmqinst -l hareplica -e yes
  7. This command specifies that the installation is no longer a High Availability Replica:
    setmqinst -l hareplica -e no


Related information