Anyone knows which entries I must filter in order to get start/stop of sessions only?
Would'nt want to reinvent the wheel...
WFS/FFS/DM 7.6.4 / WFS/FFS/DM 7.6.8 / WFS/FFS/DM 7.6.9 / AS400 V5R4M0 / HTML / iSM 5.5sp2
January 06, 2010, 09:23 AM
GinnyJakes
quote:
01/05/2010 20:43:02 accepting cmrpip027758 tcp=139.51.76.101:61245 01/05/2010 20:43:02 request by cmrpip027758 for explicit connect to agent (DEFAULT) 01/05/2010 20:43:02 connecting cmrpip027758 tscomid=306,sesid=27477 01/05/2010 20:43:02 processing cmrpip027758 u=udwfadmn,g=webfocus,l=USR 01/05/2010 20:43:02 request by t3rp835616 to notify disconnect of sesid=27477 01/05/2010 20:43:02 disconnect cmrpip027758 tscomid=306,sesid=27477
Here is a series from edaprint.log that shows the life of a session. You should be able to tell from this pattern what you need to extract to determine start/stop. I would suggest the 'connecting' and the 'disconnect' lines. Please bear in mind that there may be intervening lines for other sessions so you'll probably have to hold the sorted output before doing any kind of meaningful report.
I defined the edaprint file in the master file instead of the fex... probably not the best way to do this but it's the only way I could get the synonym to produce some data when doing a sample data...
And when I try to define the file in a fex, it gets worse... It refuses to parse FILEDEF... But I'm just starting on this and got not much training.
WFS/FFS/DM 7.6.4 / WFS/FFS/DM 7.6.8 / WFS/FFS/DM 7.6.9 / AS400 V5R4M0 / HTML / iSM 5.5sp2
January 06, 2010, 05:29 PM
GinnyJakes
I'm working on trying to homogenize the file but won't get it done today. More tomorrow.
FILEDEF MAS DISK EDAPRINT.MAS FILEDEF EDAPRINT DISK C:\ibi\DevStudio76\srv76\wfs\EDAPRINT.LOG -RUN -WRITE MAS FILENAME=EDAPRINT , SUFFIX=FIX , $ -WRITE MAS SEGMENT=EDAPRINT, SEGTYPE=S0, $ -WRITE MAS FIELDNAME=LOGTIME, ALIAS=LOGTIME, USAGE=A19, ACTUAL=A20, $ -WRITE MAS FIELDNAME=LOGDATA, ALIAS=LOGDATA, USAGE=A80, ACTUAL=A80, $ DEFINE FILE EDAPRINT USER /A7= IF LOGDATA CONTAINS 'processing' THEN EDIT(LOGDATA,'$$$$$$$$$$$$$$$$$$$$$$$$$$9999999'); START/A19=IF LOGDATA CONTAINS 'connecting' THEN LOGTIME ELSE ''; ENDTIME/A19=IF LOGDATA CONTAINS 'disconnect' THEN LOGTIME ELSE ''; CRMPIP/A12=EDIT(LOGDATA,'$$$$$$$$$$$999999999999'); END TABLE FILE EDAPRINT SUM USER MAX.START MAX.ENDTIME BY CRMPIP WHERE LOGDATA EQ 'connecting$*' OR 'disconnect$*' OR 'processing$*' END
January 07, 2010, 09:31 AM
Pascal Bellerose
Great!!! Thanks JG, I found out I didn't have to put the filepath in quotation marks.
I thought I ruled out this option but obviously, I did not.
Your code helped me with teh cleaning of unecessary text in the log and get to the essential.
I'm working on filtering agents start/stop and IP that is connecting. I will post my results!
Thanks again!
WFS/FFS/DM 7.6.4 / WFS/FFS/DM 7.6.8 / WFS/FFS/DM 7.6.9 / AS400 V5R4M0 / HTML / iSM 5.5sp2