From: Josh Durgin Date: Mon, 24 Mar 2014 21:13:07 +0000 (-0700) Subject: internal: ignore binary junk in kernel logs X-Git-Tag: 1.1.0~1577 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b677bdd1bb95f1bc70a9d666f0ffb42ca2f3a2b0;p=teuthology.git internal: ignore binary junk in kernel logs NUL bytes can show up here after powercycle testing Signed-off-by: Josh Durgin --- diff --git a/teuthology/task/internal.py b/teuthology/task/internal.py index 4bcb89ec..00b179a2 100644 --- a/teuthology/task/internal.py +++ b/teuthology/task/internal.py @@ -488,9 +488,13 @@ kern.* -{adir}/syslog/kern.log;RSYSLOG_FileFormat log.debug('Checking %s', remote.name) r = remote.run( args=[ + 'cat', + run.Raw('{adir}/syslog/*.log'.format(adir=archive_dir)), + run.Raw('|'), + 'tr', '[\\000-\\011\\013-\\037\\177-\\377]', '.', + run.Raw('|'), 'egrep', '\\bBUG\\b|\\bINFO\\b|\\bDEADLOCK\\b', - run.Raw('{adir}/syslog/*.log'.format(adir=archive_dir)), run.Raw('|'), 'grep', '-v', 'task .* blocked for more than .* seconds', run.Raw('|'),