+

Search Tips | Advanced Search

MQCHLLIB

MQCHLLIB specifies the directory path to the file containing the client channel definition table (CCDT). The file is created on the server, but can be copied across to the IBM MQ MQI client workstation.

If MQCHLLIB is not set, the path for the client defaults to:

  • On Windows: MQ_INSTALLATION_PATH
  • On UNIX and Linux : /var/mqm/
  • On IBM i: /QIBM/UserData/mqm/

For the crtmqm and strmqm commands, the path defaults to one of two sets of paths. If datapath is set, the path defaults to one of the first set. If datapath is not set, the path defaults to one of the second set.

  • On Windows: datapath\@ipcc
  • On UNIX and Linux: datapath/@ipcc
  • On IBM i: datapath/&ipcc

Or:

  • On Windows: MQ_INSTALLATION_PATH\data\qmgrs\qmgrname\@ipcc
  • On UNIX and Linux: /prefix/qmgrs/qmgrname/@ipcc
  • On IBM i: /prefix/qmgrs/qmgrname/&ipcc

where:

  • MQ_INSTALLATION_PATH represents the high-level directory in which IBM MQ is installed.
  • If present, datapath is the value of DataPath defined in the queue manager stanza.
  • prefix is the value of Prefix defined in the queue manager stanza. Prefix is typically one of the following values:

    • /var/mqm on UNIX and Linux systems.
    • /QIBM/UserData/mqm/ on IBM i.

  • qmgrname is the value of the Directory attribute defined in the queue manager stanza. The value might be different from the actual queue manager name. The value might have been altered to replace special characters.
  • Where the queue manager stanza is defined depends on the platform:

    • In the mqs.ini file on IBM i, UNIX, and Linux.
    • In the registry on Windows.

Notes:

  1. If we are using IBM MQ for z/OS as your server, the file must be kept on the IBM MQ client workstation.
  2. If set, MQCHLLIB overrides the path used to locate the CCDT.
  3. MQCHLLIB can contain a URL which works in combination with the MQCHLTAB environment variable (see URL access to the CCDT).
  4. Environment variables, such as MQCHLLIB, can be scoped to a process, or a job, or system-wide, in a platform-specific way.
  5. If you set MQCHLLIB system-wide on a server, it sets the same path to the CCDT file for all the queue managers on the server. If we do not set the MQCHLLIB environment variable, the path is different for each queue manager. Queue managers read the value of MQCHLLIB, if it is set, on either the crtmqm or strmqm command.
  6. If you create multiple queue managers on one server, the distinction is important, for the following reason. If you set MQCHLLIB system-wide, each queue manager updates the same CCDT file. The file contains the client-connection definitions from all the queue managers on the server. If the same definition exists on multiple queue managers, SYSTEM.DEF.CLNTCONN for example, the file contains the latest definition. When creating a queue manager, if MQCHLLIB is set, SYSTEM.DEF.CLNTCONN is updated in the CCDT. The update overwrites the SYSTEM.DEF.CLNTCONN created by a different queue manager. If you modified the earlier definition, your modifications are lost. For this reason, we must consider finding alternatives to setting MQCHLLIB as a system-wide environment variable on the server.
  7. The MQSC and PCF NOREPLACE option on a client-connection definition does not check the contents of the CCDT file. A client-connection channel definition of the same name that was previously created, but not by this queue manager, is replaced, regardless of the NOREPLACE option. If the definition was previously created by the same queue manager, the definition is not replaced.
  8. The command, rcrmqobj -t clchltab deletes and re-creates the CCDT file. The file is re-created with only the client-connection definitions created on the queue manager that the command is running against.
  9. Other commands that update the CCDT modify only the client-connection channels that have the same channel name. Other client-connection channels in the file are not altered.
  10. The path for MQCHLLIB does not need quotations marks.


Examples

To set this variable use one of these commands:

  • On Windows:
    SET MQCHLLIB=pathname
    
    For example:
    SET MQCHLLIB=C:\wmqtest
    
  • For UNIX and Linux systems:
    export MQCHLLIB=pathname
    
  • For IBM i:
    ADDENVVAR ENVVAR(MQCHLLIB) VALUE(pathname)
    

Parent topic: Use IBM MQ environment variables


Related reference


Related information

Last updated: 2020-10-04