Académique Documents
Professionnel Documents
Culture Documents
MQServer)
verified: Windows-ME (MQ client) to Windows-2000 (MQ server)
Basic Connectivity...
<sr> C:\>
<ur> CD C:\MQClient\Bin
<sr> C:\mqclient\BIN>
<ur> dir *.exe
11. Program "amqscnxc.exe" is used to test general "client -> server" connectivity (and also
demos the use of the new MQCONNX call). View this program's command line
arguments like so...
12. <sr> C:\mqclient\BIN>
13. <ur> amqscnxc -?
<sr> amqscnxc [-x ConnName [-c SvrconnChannelName]] [QMgrName]
1. the "-x" switch specifies the I/P address of the other machine. Port 1414 is used
by default
2. Sample Note: source code file "amqscnxc.c" is found with "MQSeries for
Windows-NT and Windows-2000" but not "MQSeries Client for Windows 95, 98
and Me - V5.2". You may want to peek at this file to learn how MQCONNX
allows the client to connect without the use of environment variable MQSERVER
or channel definition file "AMQCLCHL.TAB"
14. This is an example of a good session...
15.
16. <sr> C:\mqclient\BIN>
17. <ur> amqscnxc -x 192.168.1.220
18. <sr> Connecting to the default queue manager
19. using the server connection channel SYSTEM.DEF.SVRCONN
20. on connection name 192.168.1.220.
21. Connection established to queue manager QM_rieck2
Sample AMQSCNXC end
Program Names
DISPLAY CHANNEL(*)
notice that one of them is SYSTEM.DEF.SVRCONN which we'll assume is the default
server connection
3. on the client machine, from an "MS-DOS" prompt, define an environmental variable
using one of the channels just acquired like so:
SET MQSERVER=SYSTEM.DEF.SVRCONN/TCP/192.168.1.220
4. type: SET (to view your environment variables)
5. This is an example of a good session:
6. <sr> C:\mqclient\BIN>
7. <ur> amqsgetc default
8. <sr> Sample AMQSGET0 start
9. no more messages
Sample AMQSGET0 end
10. reason code 2059 means that you made a typo in the CHANNEL (first third) of the
MQSERVER variable.
11. reason code 2085 means that you made a typo in the queue name
9. Now run the program again and you should get this:
10. <sr> C:\mqclient\BIN>
11. <ur> amqsgetc default<sr> Sample AMQSGET0 start
12. no more messages
Sample AMQSGET0 end
need environment
variable
or channel definition
command function
file
"AMQCLCHL.TAB
"?
tests basic connectivity using
>amqscnxc -x 192.168.1.200 n
MQCONNX
>amqsputc default string message put y
>amqsgbrc default message browse y
>amqsgets default string message get y
>amqsprmc -q default -i yada.txt -t
reference message (file) put y
FLATFILE
Programmers may wish to use a shorter path (for source headers, linker objects,
etc.) so during an install or upgrade, it is probably a good idea to install the MQ
client software in folder "C:\MQClient" rather than the default location. Note that
the installation folder directory can always be changed when the installation mode
is "Custom" rather than "Typical".