]>
Commit | Line | Data |
---|---|---|
d1513470 | 1 | # marian.ivanov@cern.ch |
2 | # Filter error logs | |
3 | # Input - errRec.logs - text file with the list of error logs | |
80af44ba | 4 | # Output - abort.log - text file with the seg.faults runs |
5 | # - abortout.log - text file with the output of the seg.fault runs | |
6 | # - the err.log and out.log suppose to be in the same directory | |
7 | # -syswatchAbort.log | |
84ddafc8 | 8 | # |
9 | isOK=0 | |
d1513470 | 10 | nonOK=0 |
80af44ba | 11 | # |
84ddafc8 | 12 | rm abort.log |
13 | rm abortout.log | |
80af44ba | 14 | rm syswatchAbort.log |
15 | rm syswatchAll.log | |
05e3ee70 | 16 | echo hname/C:sname/C:id0/I:id1/I:id2/I:first/D:stampSec/D:mi.fMemUsed/D:mi.fSwapUsed/D:cI.fUser/D:cI.fSys/D:pI.fMemResident/D:pI.fMemVirtual/D:pI.fCpuUser/D:pI.fCpuSys/D:stampOldSec/D:miOld.fMemUsed/D:miOld.fSwapUsed/D:cIOld.fUser/D:cIOld.fSys/D:pIOld.fMemResident/D:pIOld.fMemVirtual/D:pIOld.fCpuUser/D:pIOld.fCpuSys/D > syswatchAbort.log |
17 | echo hname/C:sname/C:id0/I:id1/I:id2/I:first/D:stampSec/D:mi.fMemUsed/D:mi.fSwapUsed/D:cI.fUser/D:cI.fSys/D:pI.fMemResident/D:pI.fMemVirtual/D:pI.fCpuUser/D:pI.fCpuSys/D:stampOldSec/D:miOld.fMemUsed/D:miOld.fSwapUsed/D:cIOld.fUser/D:cIOld.fSys/D:pIOld.fMemResident/D:pIOld.fMemVirtual/D:pIOld.fCpuUser/D:pIOld.fCpuSys/D > syswatchAll.log | |
80af44ba | 18 | |
80af44ba | 19 | |
20 | # | |
d1513470 | 21 | for efile in `cat errRec.log` ;do |
22 | xxx=`cat $efile| grep segmentation` | |
84ddafc8 | 23 | xxx=$xxx`cat $efile| grep Aborted` |
05e3ee70 | 24 | xxx=$xxx`cat $efile| grep floating` |
25 | sysfile=`echo $efile| sed s_err_syswatch_` | |
80af44ba | 26 | # |
27 | if [ -z "$xxx" ] | |
84ddafc8 | 28 | then |
29 | let isOK=isOK+1 | |
30 | else | |
31 | let nonOK=nonOK+1 | |
32 | echo nonOK=$nonOK | |
33 | echo "$efile" >>abort.log | |
34 | echo $efile | |
35 | ofile=`echo $efile| sed s_err_out_` | |
80af44ba | 36 | cat $ofile >> abortout.log |
1d980c30 | 37 | #cat $sysfile | grep -v hname\/C:sname\/C: >> syswatchAbort.log |
84ddafc8 | 38 | fi |
1d980c30 | 39 | #cat $sysfile | grep -v hname\/C:sname\/ >> syswatchAll.log |
d1513470 | 40 | done; |
80af44ba | 41 | |
05e3ee70 | 42 | # |
43 | # connection problems | |
44 | # | |
45 | rm networkProblem.log | |
46 | touch networkProblem.log | |
47 | netOK=0; | |
48 | netNonOK=0; | |
49 | for efile in `cat errRec.log` ;do | |
50 | xxx=`cat $efile| grep tcp_connect` | |
51 | if [ -z "$xxx" ] | |
52 | then | |
53 | let netOK=netOK+1 | |
54 | else | |
55 | let netNonOK=netNonOK+1 | |
56 | echo $efile >> networkProblem.log | |
57 | fi; | |
58 | done; | |
59 | # | |
60 | # Print stat | |
61 | # | |
d1513470 | 62 | echo isOK=$isOK nonOK=$nonOK |
05e3ee70 | 63 | echo netOK=$netOK netNonOK=$netNonOK |
64 | # | |
65 | # filter segmentation fault | |
66 | # | |
67 | rm seg0.out | |
68 | for a in `cat abort.log |sed s_err_out_ ` ;do | |
69 | cat $a | grep 0x | grep \# >> seg0.out | |
70 | done; |