…elogs greppen
eigentlich nur für mich selbst, damit ich es nicht jedes mal neu suchen muss:
in den elogs (/fnsw/local/logs/elogs/elogYYYYMMDD) sind kritische fehler mit “[SERIOUS]” zu erkennen - danach zu greppen ist also ohne probleme möglich. allerdings steht die wichtige information erst in der zeile danach:
2007/12/31 09:26:37.532 121,0,41
INXbg -s IndexServer (4513) … [SERIOUS]
Oracle not available. (ORA-3113), (File: ../src/GDBO.c, Line 3823)
daher reicht ein normales grep nicht - aber awk kann helfen:
export R=SERIOUS
awk ‘{if ($0~/’$R’/) {print $0; n=1} else { if (n==1) {print $0; n=0}}}’ elogYYYYMMDD
Related posts:
- spaß mit dem oracle client
- iisreset? iisapp.vbs reicht!
- BDC Meta Man - try Oracle, DB2, Web Services, MS Access now in Developer version
- Citrix AddPrinter Utility
Make A Comment: ( 2 so far )
2 Responses to “…elogs greppen”
Martin Leyrer
wrote on
March 14, 2008 @ 20:34 (in other words: 9 hours, 2 minutes after the fact)





grep mit der Option “-C 1″ oder “-C 2″ wäre auch Möglich, oder?