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 » Mainframe, CICS, TXSeries » csq1logp utility

Post new topic  Reply to topic Goto page 1, 2, 3  Next
 csq1logp utility « View previous topic :: View next topic » 
Author Message
giuly020277
PostPosted: Mon Mar 07, 2011 1:58 am    Post subject: csq1logp utility Reply with quote

Centurion

Joined: 07 Aug 2007
Posts: 146
Location: Florence,Italy

Hello everyone,
i work with Mqseries (v. 7) on zos(v.10).
Reading system admin guide i found an interesting utility :csq1logp with extract.

I'd like to :
v Review which persistent messages were put to or got from a queue and whether the request was committed. This allows messages to be replayed.
v Review persistent messages that were put or got, but the request was backed out.
v Display which applications backed out rather than committed. v Discover the volume of persistent data processed by queues, to identify the high use queues.
v Identify which applications set object attributes. v Recreate object definitions for recovery purposes after a major failure

but i'm not able to write a jcl who run successfully

I have tried with these one...

//PRTLOG EXEC PGM=CSQ1LOGP
//STEPLIB DD DISP=SHR,DSN=PPTESTL.MQSERIES.SCSQANLE
// DD DISP=SHR,DSN=PPTESTL.MQSERIES.SCSQLOAD
//BSDS DD DSN=MQTESTV.MFET.BSDS01,DISP=SHR
// DD DSN=MQTESTV.MFET.BSDS02,DISP=SHR
//*ACTIVE1 DD DSN=MQTESTV.MFET.LOGCOPY1.DS01,DISP=SHR
//*ACTIVE2 DD DSN=MQTESTV.MFET.LOGCOPY1.DS02,DISP=SHR
//*ACTIVE3 DD DSN=MQTESTV.MFET.LOGCOPY1.DS03,DISP=SHR
//*ACTIVE4 DD DSN=MQTESTV.MFET.LOGCOPY1.DS04,DISP=SHR
//*ARCHIVE DD DSN=MQTESTV.MFET.LOGCOPY2.DS01,DISP=SHR
//* DD DSN=MQTESTV.MFET.LOGCOPY2.DS02,DISP=SHR
//* DD DSN=MQTESTV.MFET.LOGCOPY2.DS03,DISP=SHR
//* DD DSN=MQTESTV.MFET.LOGCOPY2.DS04,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSSUMRY DD SYSOUT=*
//SYSIN DD *
PAGESET(00)
RBASTART(000000000000)
RBAEND(FFFFFFFFFFFF)
SUMMARY(YES)
EXTRACT(YES)
//csqback dd dsn=ecc
//csqcmt dd ...
//csqboth dd ...
//csqinflt dd ..and so on

but never run ok.

Someone can help me to find a way (or a jcl ) ?
Thank u all
Back to top
View user's profile Send private message
Mr Butcher
PostPosted: Mon Mar 07, 2011 2:55 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

what do you get? jcl error? messages from csq1logp?

I have not used the V7 version so far, but for V6 i always used a "ARCHIVE" DD statement to access the archives i want to access. In your jcl, this is all comment except the BSDS

just a quick guess....

in addition, csq1logp produces quite a log of output. depending on how long your queuemanager exists you may need lots of space on dasd and jes spool for the whole RBA range. Start with a more simple job (e.g. only the summary) and a single log archive. if that works, then put in the other stuff.

if i know i have to run multiple jobs on the same archive, then i copy it to disk first (my archive is on tape).

here is a simple job with archive already loaded to disk. my mq libs are in the lnklst.

Code:

//CSQ      EXEC PGM=CSQ1LOGP                                 
//SYSPRINT DD SYSOUT=*                                       
//SYSSUMRY DD SYSOUT=*                                       
//ARCHIVE  DD DISP=SHR,DSN=Z.CSQ5.A0010397             
//SYSIN    DD *                                             
SUMMARY(ONLY)                                                 
/*                                                           

_________________
Regards, Butcher


Last edited by Mr Butcher on Mon Mar 07, 2011 3:02 am; edited 1 time in total
Back to top
View user's profile Send private message
giuly020277
PostPosted: Mon Mar 07, 2011 2:58 am    Post subject: Reply with quote

Centurion

Joined: 07 Aug 2007
Posts: 146
Location: Florence,Italy

i got :

CSQ1221E VSAM ERROR, RETCODE=0000000C REASON CODE=00D10013, VSAM RETURN CODE=0008, ERROR CODE=00BC


CSQ1101I CSQ1LOGP UTILITY PROCESSING COMPLETED, RETURN CODE=12
Back to top
View user's profile Send private message
giuly020277
PostPosted: Mon Mar 07, 2011 3:16 am    Post subject: Reply with quote

Centurion

Joined: 07 Aug 2007
Posts: 146
Location: Florence,Italy

OK MR BUTCHER...

I HAVE USED YOUR JCL

//F3599P00 JOB CLASS=Q,MSGCLASS=Y
//PRTLOG EXEC PGM=CSQ1LOGP
//STEPLIB DD DISP=SHR,DSN=PPTESTL.MQSERIES.SCSQANLE
// DD DISP=SHR,DSN=PPTESTL.MQSERIES.SCSQLOAD
//ARCHIVE DD DSN=MQTESTS.MFETARC1.A0000101,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSSUMRY DD SYSOUT=*
//SYSIN DD *
SUMMARY(ONLY)
/*

IT WORKS...BUT NOW I DON'T KNOW HOW TO READ THE RESULTS :

CONNID=MFET THREAD-XREF=201.SCAVNG01 USERID=SYSOPR
TIME=2011-03-05 09:11:00 START=000154FC8F6F END=000154FC910F
DISP=COMMITTED INFO=COMPLETE

CONNID=MFET THREAD-XREF=213.RTSSRV01 USERID=OMEGA
TIME=2011-03-05 09:15:25 START=000154FCBC4B END=000154FCC1B5
DISP=COMMITTED INFO=COMPLETE

CONNID=MFET THREAD-XREF=213.RTSSRV01 USERID=MFETCHIN
TIME=2011-03-05 09:15:25 START=000154FCDD88 END=000154FCE25A
DISP=COMMITTED INFO=COMPLETE

..AND MORE
Back to top
View user's profile Send private message
giuly020277
PostPosted: Mon Mar 07, 2011 3:18 am    Post subject: Reply with quote

Centurion

Joined: 07 Aug 2007
Posts: 146
Location: Florence,Italy

I'd like to :
v Review which persistent messages were put to or got from a queue and whether the request was committed. This allows messages to be replayed.
v Review persistent messages that were put or got, but the request was backed out.
v Display which applications backed out rather than committed. v Discover the volume of persistent data processed by queues, to identify the high use queues.
v Identify which applications set object attributes. v Recreate object definitions for recovery purposes after a major failur


WHAT I HAVE TO DO TO KNOW THESE INFORMATION?
Back to top
View user's profile Send private message
Mr Butcher
PostPosted: Mon Mar 07, 2011 4:36 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

well, the summary gives you a summary of the units of work recorded in the log. start time, rba start, rba end, userid, ..... just read what you get.

your request is quoted exactly from the manual. so why don't you just do what the manuals says? the manual also reads to use csq1logp only on a portion of the logs. it also has sample jobs for processing bsds, active or archive logs. your first try whas a bsds job, but you wanted to use it on the archive. so read the csq1logp section again, and carefully.
then get an archive, create an extract and WYSIWYG

IBM does not tell you much about the log and the content and nothing about the structure. its all secret. so ... its always up to you to interpret the output of csq1logp. if you want to learn ... have a sample program that e.g. does a mqput. have another sample program that does the mqget of the message you put before. then try to find both UOWs in the log and interpret the output of csq1logp.
_________________
Regards, Butcher
Back to top
View user's profile Send private message
gouda
PostPosted: Wed Mar 09, 2011 6:24 am    Post subject: Reply with quote

Apprentice

Joined: 20 May 2001
Posts: 32
Location: Germany, Nuremburg

You cannot use BSDS and active log unless the qmgr is down, therefore you got the vsam error.
So the suggestion of Mr.Butcher to use archives is the right one.

We only use CSQ1LOGP to find a written evidence for messages if someone won't believe that they were/weren't written/read .
Some kind of Sherlock Holmes behaviour.

We have two jobsteps:
First CSQ1LOGP with really very large output datasets for
//CSQINFLT
//CSQCMT
//CSQBACK
//CSQOBJS
Then some self written REXX procedure to filter the log records. You have
- the action(MQGET/MQPUT/ALTER/DEFINE/EXPIRE/PHASE1/PHASE2/ABORT2) at byte 174
- the object name at byte 106
- and the message including headers at byte 202.
The message itself is not shown within MQGET.
http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/topic/com.ibm.mq.csqsaw.doc/za14150_.htm

We use BatchpipeWorks to accelerate the REXX.
You normally have thousands of cylinders to process.
_________________
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots.
So far, the Universe is winning.
https://en.wikiquote.org/wiki/Rick_Cook
Back to top
View user's profile Send private message
Mr Butcher
PostPosted: Wed Mar 09, 2011 6:55 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

I sometimes have to prove the same, but my approach is a bit different.

In most cases the time range is known, so i know which archives i need to process. If i dont want to search the whole archive i take a summary first and use RBASTART RBAEND to limit the range i search.

I then use the "DATA(....)" statements to find the proper messages in the archive log, e.g. by unique reference fields (application data).

If you find the message, then you can have a look at the UOW. You also know the place in the pageset the message has been written to (LRID), so if you continue from that point and search for that LRID you find the UOW that processed the message.

So i can tell exactly when a message hit my system, and when (and by whom) it was processed and if there was any backout or not.

I only need little spool space for this (except the summary is a bit bigger if needed).... logs can be accessed directly from tape.


different approach, same result. i must try your method one day ...
_________________
Regards, Butcher
Back to top
View user's profile Send private message
gouda
PostPosted: Wed Mar 09, 2011 7:28 am    Post subject: Reply with quote

Apprentice

Joined: 20 May 2001
Posts: 32
Location: Germany, Nuremburg

Of course we also make a limitation by pageset and time frame(=archive dataset) when searching.
The biggest advantage is the piping which results in a very fast processing.
Back to top
View user's profile Send private message
bruce2359
PostPosted: Wed Mar 09, 2011 7:39 am    Post subject: Reply with quote

Poobah

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

I seem to recall a 3rd-party vendor that has an application to scrape data from the logs... is it Cressida?
_________________
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
giuly020277
PostPosted: Fri Mar 11, 2011 2:50 am    Post subject: Reply with quote

Centurion

Joined: 07 Aug 2007
Posts: 146
Location: Florence,Italy

hello...
finally i got a report who can help me understanding which messages flow on Mq.

Just a problem.
If Mqput is done from a CICs transcaction...i'm able to read the messages.
If Mqput is done from "Websphere mq client for java" or from sun solaris i can't read messages because of their format.

An example :

TMAT 2011031015402337 021349258
DSTU 2011031015402403 000000000CRPSNT49C50G604L10089


DSTU 2011031015402465 021344960MNNGNN83T23B780G10031

MQ Client for Java 2011031015402468 ......................... ....

MQ Client for Java 2011031015402474 {<áå..........................



e MQ Client for Java 2011031015402494 ......................... !...

e MQ Client for Java 2011031015402545 <ñ]íñ{ éñ!+á..................

e MQ Client for Java 2011031015402602 (í<}ñä\ñ ( } .................
What i have to do te be able to read these on?
Back to top
View user's profile Send private message
giuly020277
PostPosted: Fri Mar 11, 2011 2:56 am    Post subject: Reply with quote

Centurion

Joined: 07 Aug 2007
Posts: 146
Location: Florence,Italy

[quote="gouda"]The message itself is not shown within MQGET.
quote]

Why messages are not show within mqget?
Back to top
View user's profile Send private message
Mr Butcher
PostPosted: Fri Mar 11, 2011 4:09 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

most likely you have to convert from ascii to ebcdic to read it. i have the same problem with CSQ1LOGP output when i search for message content. i always search for the ascii and the ebcdic values, and i have a little procedure that translates the csq1logp print output so i have 2 columns next to the hex values, in one i can read ebcdic and one i can read ascii (translated to ebcdic)
_________________
Regards, Butcher
Back to top
View user's profile Send private message
giuly020277
PostPosted: Fri Mar 11, 2011 4:32 am    Post subject: Reply with quote

Centurion

Joined: 07 Aug 2007
Posts: 146
Location: Florence,Italy

ok...so i have to translate that lines from ascii to ebcdic.

have u Mr butcher a jcl who can do it? which utility u use?
Back to top
View user's profile Send private message
Mr Butcher
PostPosted: Fri Mar 11, 2011 4:39 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

i use some rexx .....


have two "codepages"

Code:
toEBCDIC =           '00010203372D2E2F1605250B0C0D0E0F'x  /* 00 */   
toEBCDIC = toEBCDIC!!'101112133C3D322618193F271C1D1E1F'x  /* 10 */   
toEBCDIC = toEBCDIC!!'405A7F7B5B6C507D4D5D5C4E6B604B61'x  /* 20 */   
toEBCDIC = toEBCDIC!!'F0F1F2F3F4F5F6F7F8F97A5E4C7E6E6F'x  /* 30 */   
toEBCDIC = toEBCDIC!!'7CC1C2C3C4C5C6C7C8C9D1D2D3D4D5D6'x  /* 40 */   
toEBCDIC = toEBCDIC!!'D7D8D9E2E3E4E5E6E7E8E9ADE0BD5F6D'x  /* 50 */   
toEBCDIC = toEBCDIC!!'79818283848586878889919293949596'x  /* 60 */   
toEBCDIC = toEBCDIC!!'979899A2A3A4A5A6A7A8A9C04FD0A107'x  /* 70 */   
toEBCDIC = toEBCDIC!!'202122232415061728292A2B2C090A1B'x  /* 80 */   
toEBCDIC = toEBCDIC!!'30311A333435360838393A3B04143EFF'x  /* 90 */   
toEBCDIC = toEBCDIC!!'41AA4AB19FB26AB5BBB49A8AB0CAAFBC'x  /* A0 */   
toEBCDIC = toEBCDIC!!'908FEAFABEA0B6B39DDA9B8BB7B8B9AB'x  /* B0 */   
toEBCDIC = toEBCDIC!!'6465626663679E687471727378757677'x  /* C0 */   
toEBCDIC = toEBCDIC!!'AC69EDEEEBEFECBF80FDFEFBFCBAAE59'x  /* D0 */   
toEBCDIC = toEBCDIC!!'4445424643479C485451525358555657'x  /* E0 */   
toEBCDIC = toEBCDIC!!'8C49CDCECBCFCCE170DDDEDBDC8D8EDF'x  /* F0 */   

toASCII =          '000102039C09867F978D8E0B0C0D0E0F'x  /* 00 */     
toASCII = toASCII!!'101112139D8508871819928F1C1D1E1F'x  /* 10 */     
toASCII = toASCII!!'80818283840A171B88898A8B8C050607'x  /* 20 */     
toASCII = toASCII!!'909116939495960498999A9B14159E1A'x  /* 30 */     
toASCII = toASCII!!'20A0E2E4E0E1E3E5E7F1A22E3C282B7C'x  /* 40 */     
toASCII = toASCII!!'26E9EAEBE8EDEEEFECDF21242A293B5E'x  /* 50 */     
toASCII = toASCII!!'2D2FC2C4C0C1C3C5C7D1A62C255F3E3F'x  /* 60 */     
toASCII = toASCII!!'F8C9CACBC8CDCECFCC603A2340273D22'x  /* 70 */     
toASCII = toASCII!!'D8616263646566676869ABBBF0FDFEB1'x  /* 80 */     
toASCII = toASCII!!'B06A6B6C6D6E6F707172AABAE6B8C6A4'x  /* 90 */     
toASCII = toASCII!!'B57E737475767778797AA1BFD05BDEAE'x  /* A0 */     
toASCII = toASCII!!'ACA3A5B7A9A7B6BCBDBEDDA8AF5DB4D7'x  /* B0 */     
toASCII = toASCII!!'7B414243444546474849ADF4F6F2F3F5'x  /* C0 */     
toASCII = toASCII!!'7D4A4B4C4D4E4F505152B9FBFCF9FAFF'x  /* D0 */     
toASCII = toASCII!!'5CF7535455565758595AB2D4D6D2D3D5'x  /* E0 */     
toASCII = toASCII!!'30313233343536373839B3DBDCD9DA9F'x  /* F0 */     

then use translate to convert

Code:
newstr = translate(oldstr,toEBCDIC)     


or

Code:
newstr = translate(oldstr,toASCII)                 



of course this is quick and dirty and does not cover differences between ascii code pages. its just to enable you to read text. if you want to convert accurate, you must take the CCSID value from the MQ header and have the proper codepages available for translation ....

i think i googled that from somewhere ....
_________________
Regards, Butcher
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page 1, 2, 3  Next Page 1 of 3

MQSeries.net Forum Index » Mainframe, CICS, TXSeries » csq1logp utility
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.