| 1 | |
| 2 | = JMD Log Files = |
| 3 | |
| 4 | As already discussed, a JMD log file will have a name similar to "2014_02_10.NSO.stderrout.log" and will log successful downloads with lines like : |
| 5 | |
| 6 | {{{ |
| 7 | Feb 10, 2014 1:12:38 AM org.vso.jmd.Downloader.SCPDownloader call INFO: Th ID:[9254]; SU:[528482910]; RN:[131877503];[aia.lev1];[MIRROR]; Sz:[11275255]; STP:[DONE]; ST:[DONE] [611.72174KB/s] [SAO] |
| 8 | }}} |
| 9 | |
| 10 | Failures will be recorded with lines like : |
| 11 | |
| 12 | {{{ |
| 13 | Feb 10, 2014 12:07:25 AM org.vso.jmd.Downloader.SCPDownloader call INFO: Th ID:[9235]; SU:[528417849]; RN:[131843041];[aia.lev1];[MIRROR]; Sz:[7626390]; STP:[SCP]; ST:[FAIL] [N/A] [JSOC] |
| 14 | }}} |
| 15 | |
| 16 | Thus, a simple failure and success counts can be achieved with : |
| 17 | |
| 18 | {{{ |
| 19 | grep FAIL 2014_02_10.NSO.stderrout.log | wc -l |
| 20 | grep DONE 2014_02_10.NSO.stderrout.log | wc -l |
| 21 | }}} |
| 22 | |
| 23 | However, it may be more useful to break the failure/success counts down by site, with a bash script like so : |
| 24 | |
| 25 | {{{ |
| 26 | jmdLogDir=/my/jmd/log/dir |
| 27 | jmdLogFile=`/bin/ls -C1 $jmdLogDir/*.stderrout.log | sort | tail -2 | head -1` |
| 28 | echo Yesterday\'s JMD downloads according to $jmdLogFile |
| 29 | grep '\[DONE\]' $jmdLogFile | cut -d\; -f8 | cut -d" " -f4 | sort | uniq -c |
| 30 | echo Yesterday\'s failed JMD downloads : |
| 31 | grep '\[FAIL\]' $jmdLogFile | cut -d\; -f8 | cut -d" " -f4 | sort | uniq -c |
| 32 | echo |
| 33 | }}} |
| 34 | |
| 35 | which will generate output similar to this : |
| 36 | |
| 37 | {{{ |
| 38 | Yesterday's JMD downloads according to /opt/JMD/log/2014_02_04.NSO.stderrout.log |
| 39 | 66564 [JSOC] |
| 40 | 31356 [SAO] |
| 41 | Yesterday's failed JMD downloads : |
| 42 | 1 [JSOC] |
| 43 | |
| 44 | }}} |