PATH=/usr/xpg4/bin:/usr/bin
# add SUMM field and end of record marker on stat lines
awk '{print $0"|SUMM=N|EOR"}' |\
# format the STAT file, putting each field on a separate line
tr '|' '\012' |\
# separate times from dates and reformat source and destination file fields
# to have a space after the =
awk -F= '{
if ($1=="DFIL" || $1=="SFIL") print $1 "= " $2
else if ($1=="STAR" || $1=="SSTA" || $1=="STOP" ) {
split($2,A," ")
print $1 "=" A[1] "=" A[2]
}
else print
}' |\
# execute the ndmstat.awk that comes with Connect:Direct
awk -F= -f /export/home/ndm/cdunix/ndm/bin/ndmstat.awk |\
sed 's/=>/=/g'
18:39:01|SUBM=sysx@paul|SBID=sysx|SBND=paul|SNOD=john|RECI=RSST|RECC=CAPR|TZDI=-
21600|MSGI=XSMG201I|MSST=Remote Step started.|FROM=P|RSTR=N|SNAM=step1|SFIL=/app
/fmtprt/data/sysx/send/todtrigger.200803051837.results|DFIL=todtrigger.200803051
837.results|PNOD=paul
STAR=20080305 18:39:01|PNAM=todbk|PNUM=300|SSTA=20080305 18:39:01|STRT=20080305
18:39:01|STOP=20080305 18:39:01|STPT=20080305 18:39:01|SELA=00:00:00|SUBM=sysx@p
aul|SBID=sysx|SBND=paul|SNOD=john|CCOD=0|RECI=CTRC|RECC=CAPR|TZDI=-21600|MSGI=SC
PA000I|MSST=Copy step successful.|STDL=Wed Mar 5 18:39:01 2008|CSDS=Wed Mar 5
18:39:01 2008|LCCD=0|LMSG=SCPA000I|OCCD=0|OMSG=SCPA000I|PNAM=todbk|PNUM=300|SNAM
=step1|PNOD=paul|SNOD=john|LNOD=S|FROM=P|XLAT=N|SCMP=N|ECMP=N|OERR=N|CKPT=Y|LKFL
=N|RSTR=N|RUSZ=65536|PACC=|SACC=|PPMN=|SFIL=/app/fmtprt/data/sysx/send/todtrigge
r.200803051837.results|SDS1= |SDS2= |SDS3= |SBYR=223|SFSZ=223|SRCR=1|SBYX=225|SR
UX=1|SVSQ=0|SVCN=0|SVOL=|DFIL=todtrigger.200803051837.results|PPMN=|DDS1=R|DDS2=
|DDS3= |DBYW=223|DRCW=1|DBYX=225|DRUX=1|DVSQ=0|DVCN=0|DVOL=|ICRC=N|PCRC=N|DLDR=
/appl/biller/udot/input|ETMC=9|ETMK=0|ETMU=10
===============================================================================
SELECT STATISTICS
===============================================================================
PROCESS RECORD Record Id = RSST
Process Name = todbk Stat Log Date = 03/05/2008
Process Number = 300 Stat Log Time = 18:39:01
Submitter Class =
Submitter Id = sysx@paul
Src File = /app/fmtprt/data/sysx/send/todtrigger.200803051837.results
Dest File = todtrigger.200803051837.results
From node = P
Rstr = N
SNODE = john
Completion Code = 0
Message Id = XSMG201I
Short Text = Remote Step started.
-------------------------------------------------------------------------------
PROCESS RECORD Record Id = CTRC
Process Name = todbk Stat Log Date = 03/05/2008
Process Number = 300 Stat Log Time = 18:39:01
Submitter Class =
Submitter Id = sysx@paul
Step Stop Date = 03/05/2008 Step Stop Time = 18:39:01
Step Elapsed Time= 00:00:00
From node = P
Rstr = N
SNODE = john
Completion Code = 0
Message Id = SCPA000I
Short Text = Copy step successful.
Ckpt=Y Lkfl=N Rstr=N Xlat=N Scmp=N Ecmp=N CRC=N
Local node = S
From node = P
Src File = /app/fmtprt/data/sysx/send/todtrigger.200803051837.results
Dest File = todtrigger.200803051837.results
Source Destination
Ccode =0 Ccode =0
Msgid =SCPA000I Msgid =SCPA000I
Bytes Read =223 Bytes Written=223
Recs Read =1 Recs Written=1
Bytes Sent =225 Bytes Recvd =225
Rus Sent =1 Rus Recvd =1
Ru Size =65536
-------------------------------------------------------------------------------
===============================================================================
$