Configuring your queue manager so that IBM MQ classes for JMS applications can connect in client mode
To configure your queue manager so that IBM® MQ classes for JMS applications can connect in client mode, you must create a server connection channel definition and start a listener.
Creating a server connection channel definition
DEFINE CHANNEL(JAVA.CHANNEL) CHLTYPE(SVRCONN) TRPTYPE(TCP)
On IBM i, you can use the CL
command CRTMQMCHL instead, as in the following example:
CRTMQMCHL CHLNAME(JAVA.CHANNEL) CHLTYPE(*SVRCN)
TRPTYPE(*TCP)
MQMNAME(QMGRNAME)
In this command, QMGRNAME is the name of your queue manager. ![[Windows]](ngwin.gif)
On Linux® and Windows, you can also create a server connection channel
definition using IBM MQ Explorer.
On z/OS® you can use the operations
and control panels to create a server connection channel definition .
The name of the channel (JAVA.CHANNEL in the previous examples) must be the same as the channel name specified by the CHANNEL property of the connection factory that your application uses to connect to the queue manager. The default value of the CHANNEL property is SYSTEM.DEF.SVRCONN.
Starting a listener
You must start a listener for your queue manager if one is not already started.
On Multiplatforms, you can use the MQSC command START LISTENER to
start a listener after first creating a listener object by using the MQSC command DEFINE LISTENER,
as shown in the following example:
DEFINE LISTENER(LISTENER.TCP) TRPTYPE(TCP) PORT(1414)
START LISTENER(LISTENER.TCP)
On z/OS, you use only the START
LISTENER command, as in the following example, but note that the channel initiator address space
must be started before you can start a listener:
START LISTENER TRPTYPE(TCP) PORT(1414)
On IBM i, you can also use the CL command STRMQMLSR to start a listener, as in the following example:
STRMQMLSR PORT(1414) MQMNAME(QMGRNAME)
In
this command, QMGRNAME is the name of your queue manager.
On AIX®, Linux, and Windows, you can also use the control command runmqlsr to start a listener, as in the
following example:
runmqlsr -t tcp -p 1414 -m QMgrName
In
this command, QMgrName is the name of your queue manager. ![[Windows]](ngwin.gif)
On Linux and Windows, you can also start a listener using IBM MQ Explorer.
On z/OS, you can also use the
operations and control panels to start a listener.
The number of the port on which the listener is listening must be the same as the port number specified by the PORT property of the connection factory that your application uses to connect to the queue manager. The default value of the PORT property is 1414.