ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » General IBM MQ Support » amqsevt vs amqsrua

Post new topic  Reply to topic
 amqsevt vs amqsrua « View previous topic :: View next topic » 
Author Message
paustin_ours
PostPosted: Wed Jan 06, 2021 4:12 pm    Post subject: amqsevt vs amqsrua Reply with quote

Yatiri

Joined: 19 May 2004
Posts: 667
Location: columbus,oh

i have subscribed to

$SYS/MQ/INFO/QMGR/QM92/Monitor/CPU/QMgrSummary

and i get pcf messages in my subscription queue.

when i use amqsevt to consume message from the subscription queue, the messages don't have any events.


Quote:


amqsevt -m QM92 -b -q QSUB2 -o json



Showing the last 2 records:



{

"eventSource" : { "objectName": "QSUB2",

"objectType" : "Queue" },

"eventType" : {

"name" : "None",

"value" : 0

},

"msgType" : {

"name" : "Statistics",

"value" : 21

},

"eventReason" : {

"name" : "None",

"value" : 0

},

"eventCreation" : {

"timeStamp" : "2021-01-04T19:37:44Z",

"epoch" : 1609789064

},

"eventData" : {

"queueMgrName" : "QM92",

"monitorClass" : 0,

"monitorType" : 1,

"monitorInterval" : 10015548,

"monitorFlagsNone" : 0,

"applType" : "Dos",

"codedCharSetId" : 157

}

}



{

"eventSource" : { "objectName": "QSUB2",

"objectType" : "Queue" },

"eventType" : {

"name" : "None",

"value" : 0

},

"msgType" : {

"name" : "Statistics",

"value" : 21

},

"eventReason" : {

"name" : "None",

"value" : 0

},

"eventCreation" : {

"timeStamp" : "2021-01-04T19:37:54Z",

"epoch" : 1609789074

},

"eventData" : {

"queueMgrName" : "QM92",

"monitorClass" : 0,

"monitorType" : 1,

"monitorInterval" : 10018326,

"monitorFlagsNone" : 1,

"applType" : "Vms",

"codedCharSetId" : 157

}

}



when i run command line, amqsrua -n 10 -m QM92

i get events.

what could i be missing here?
Back to top
View user's profile Send private message Yahoo Messenger
markt
PostPosted: Wed Jan 06, 2021 10:49 pm    Post subject: Reply with quote

Knight

Joined: 14 May 2002
Posts: 502

amqsevt is not a suitable tool for decoding those resource statistics, as it does not use the metadata topics to get the descriptions for the PCF elements.

That's why you see things like an "codedcharsetid" element:
MQIA_CODED_CHAR_SET_ID has the number 2, but in those PCF mesages the element "2" refers instead to a key in the metadata maps.

And that metadata is what amqsrua uses to decode them as you can see from its source code.

(Personally I'd prefer the resource stats metadata to use keys outside the MQIA/MQCA ranges - there's no reason for the key numbers to start from 0 and it would reduce the confusion as amqsevt would then just say "unknown" in these circumstances.)
Back to top
View user's profile Send private message
hughson
PostPosted: Thu Jan 07, 2021 1:35 am    Post subject: Reply with quote

Padawan

Joined: 09 May 2013
Posts: 1914
Location: Bay of Plenty, New Zealand

markt wrote:
(Personally I'd prefer the resource stats metadata to use keys outside the MQIA/MQCA ranges - there's no reason for the key numbers to start from 0 and it would reduce the confusion as amqsevt would then just say "unknown" in these circumstances.)

Me too! I tried to report the fact that it doesn't as a defect to A.Hickson, and was denied!
_________________
Morag Hughson @MoragHughson
IBM MQ Technical Education Specialist
Get your IBM MQ training here!
MQGem Software
Back to top
View user's profile Send private message Visit poster's website
bruce2359
PostPosted: Thu Jan 07, 2021 4:54 am    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9394
Location: US: west coast, almost. Otherwise, enroute.

What, if any, qmgr events did you enable before you ran amqsevt?
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
paustin_ours
PostPosted: Thu Jan 07, 2021 5:35 am    Post subject: Reply with quote

Yatiri

Joined: 19 May 2004
Posts: 667
Location: columbus,oh

I didnt enable any.

i subscribed to the topic and created a subscription queue. then used the amqsevt against that subscription queue.

using amqsrua i am able to get events with values even without enabling any queue manager events.
Back to top
View user's profile Send private message Yahoo Messenger
bruce2359
PostPosted: Thu Jan 07, 2021 7:33 am    Post subject: Re: amqsevt Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9394
Location: US: west coast, almost. Otherwise, enroute.

paustin_ours wrote:
i have subscribed to

$SYS/MQ/INFO/QMGR/QM92/Monitor/CPU/QMgrSummary

and i get pcf messages in my subscription queue.

when i use amqsevt to consume message from the subscription queue, the messages don't have any events.

How did you subscribe?

What subscription queue?

You subscribed to CPU. What events did you expect to see?

Can you be a bit more precise as to what results you expected.
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
paustin_ours
PostPosted: Thu Jan 07, 2021 8:54 am    Post subject: Reply with quote

Yatiri

Joined: 19 May 2004
Posts: 667
Location: columbus,oh

Quote:

How did you subscribe?


i created a topic and subscription from MQ explorer


Quote:
What subscription queue?

QSUB2 - local queue created on qmgr

i was hoping to get data like this



Quote:

amqsrua -n 10 -m QM92

CPU : Platform central processing units

DISK : Platform persistent data stores

STATMQI : API usage statistics

STATQ : API per-queue usage statistics

STATAPP : Per-application usage statistics

Enter Class selection

==> CPU

SystemSummary : CPU performance - platform wide

QMgrSummary : CPU performance - running queue manager

Enter Type selection

==> QMgrSummary

Publication received PutDate:20210104 PutTime:19290425 Interval:10.015 seconds

User CPU time - percentage estimate for queue manager 0.01%

System CPU time - percentage estimate for queue manager 0.02%

RAM total bytes - estimate for queue manager 157MB



Publication received PutDate:20210104 PutTime:19291425 Interval:10.006 seconds

User CPU time - percentage estimate for queue manager 0.03%

System CPU time - percentage estimate for queue manager 0.04%

RAM total bytes - estimate for queue manager 157MB
Back to top
View user's profile Send private message Yahoo Messenger
bruce2359
PostPosted: Thu Jan 07, 2021 12:35 pm    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9394
Location: US: west coast, almost. Otherwise, enroute.

Display the complete subscription definition here.

Why did you use amqsevt rather than amqsrua to display results?
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
paustin_ours
PostPosted: Thu Jan 07, 2021 12:54 pm    Post subject: Reply with quote

Yatiri

Joined: 19 May 2004
Posts: 667
Location: columbus,oh

Quote:

dis sub(CPU) all
2 : dis sub(CPU) all
AMQ8096I: IBM MQ subscription inquired.
SUBID(414D512050465245504F514D31202020C92BEE5FB0A7272B)
SUB(CPU)
TOPICSTR($SYS/MQ/INFO/QMGR/PFREPOQM1/Monitor/CPU/QMgrSummary)
TOPICOBJ(CPU) DISTYPE(RESOLVED)
DEST(QSUB2) DESTQMGR( )
PUBAPPID( ) SELECTOR( )
SELTYPE(NONE) USERDATA( )
PUBACCT(0334353000000000000000000000000000000000000000000000000000000006)
DESTCORL(414D512050465245504F514D31202020C92BEE5FB0A7272B)
DESTCLAS(PROVIDED) DURABLE(YES)
EXPIRY(UNLIMITED) PSPROP(MSGPROP)
PUBPRTY(ASPUB) REQONLY(NO)
SUBSCOPE(ALL) SUBLEVEL(1)
SUBTYPE(ADMIN) VARUSER(ANY)
WSCHEMA(TOPIC) SUBUSER(mqm)
CRDATE(2021-01-03) CRTIME(20:09:44)
ALTDATE(2021-01-03) ALTTIME(20:09:44)


amqsevt had the option to write messages out in JSON format.

Also with amqsrua i have to have a script running on the server with the different commands, CPU, DISK etc., vs if i can subscribe to this data and get them to a queue, i could read it using amqsevt [ which dont seem to work as i thought it would]
Back to top
View user's profile Send private message Yahoo Messenger
bruce2359
PostPosted: Thu Jan 07, 2021 1:32 pm    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9394
Location: US: west coast, almost. Otherwise, enroute.

paustin_ours wrote:

amqsevt had the option to write messages out in JSON format.

Ok.
paustin_ours wrote:
Also with amqsrua i have to have a script running on the server with the different commands, CPU, DISK etc., vs if i can subscribe to this data and get them to a queue, i could read it using amqsevt [ which dont seem to work as i thought it would]

Why with amqsrua do you have to have a script running on the server?
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
paustin_ours
PostPosted: Thu Jan 07, 2021 1:36 pm    Post subject: Reply with quote

Yatiri

Joined: 19 May 2004
Posts: 667
Location: columbus,oh

Quote:

Why with amqsrua do you have to have a script running on the server?


Is there a way to run it remotely?
Back to top
View user's profile Send private message Yahoo Messenger
bruce2359
PostPosted: Thu Jan 07, 2021 1:39 pm    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9394
Location: US: west coast, almost. Otherwise, enroute.

paustin_ours wrote:
Quote:

Why with amqsrua do you have to have a script running on the server?


Is there a way to run it remotely?

If memory serves, there's a amqsruac client-bindings version of amqsrua.

IBM provides source (mostly C) for sample programs.
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
paustin_ours
PostPosted: Thu Jan 07, 2021 2:08 pm    Post subject: Reply with quote

Yatiri

Joined: 19 May 2004
Posts: 667
Location: columbus,oh

you are right, there is. Will use that. thanks.
Back to top
View user's profile Send private message Yahoo Messenger
markt
PostPosted: Thu Jan 07, 2021 10:51 pm    Post subject: Reply with quote

Knight

Joined: 14 May 2002
Posts: 502

There are the Go-based collector programs, which includes a JSON variant at https://github.com/ibm-messaging/mq-metric-samples/tree/master/cmd/mq_json
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General IBM MQ Support » amqsevt vs amqsrua
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.