Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

dump a message inside a queue in MQ (Linux)

Tags:

linux

ibm-mq

mq

I want to dump a message from a queue in WebSphere MQ which is installed on a linux machine. How could I check messages inside queues with mqm authorized user? I have already checked inside opt/mqm/bin and I found some MQ commands like dmpmqaut and etc. But I can't find a command for dumping messages inside queues.

EDIT- I am using WebSphere MQ v.7.1

like image 695
A23149577 Avatar asked Dec 25 '22 20:12

A23149577


2 Answers

You don't say what version you are, but hopefully you are at a new enough version to have the dmpmqmsg command, This will dump the messages off the queue to a file.

If you are on an older version on IBM MQ that does not have this command, then the equivalent function can be used through SupportPac MO03 QLOAD. dmpmqmsg was the productisation of this free tool.

like image 79
Morag Hughson Avatar answered Dec 27 '22 08:12

Morag Hughson


A quick way to view messages on the queue if they are not too large in size is the amqsbcg sample program.

amqsbcg QUEUENAME QMGRNAME > output.file

This sample program can be found in
AIX/Unix: $MQ_HOME/samp/bin/amqsbcg
Windows: $MQ_HOME\tools\c\Samples\Bin\amqsbcg.exe

Where $MQ_HOME is the appropriate location for your operation system. The default location for $MQ_HOME is:

AIX: /usr/mqm
Unix: /opt/mqm
Windows: C:\Program Files\IBM\Websphere MQ

like image 22
ValerieLampkin Avatar answered Dec 27 '22 08:12

ValerieLampkin