From 54e8020edb7c69577b34b45d8defbab0e7c1fbf9 Mon Sep 17 00:00:00 2001 From: Michael Boelen <michael.boelen@cisofy.com> Date: Wed, 25 Jul 2018 12:13:06 +0200 Subject: [PATCH] [LOGG-2190] ignore /dev/zero and /dev/[aio] as deleted files --- include/tests_logging | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/tests_logging b/include/tests_logging index fe231f75..b7f86d8d 100644 --- a/include/tests_logging +++ b/include/tests_logging @@ -498,7 +498,7 @@ LSOF_GREP="${LSOF_GREP}|anacron|awk|run-parts" fi - FIND=$(${LSOFBINARY} -n +L 1 2>&1 | ${EGREPBINARY} -vw "${LSOF_GREP}" | ${AWKBINARY} '{ if ($5=="REG") { printf "%s(%s)\n", $10, $1 } }' | ${GREPBINARY} -v "^$" | ${SORTBINARY} -u) + FIND=$(${LSOFBINARY} -n +L 1 2>&1 | ${EGREPBINARY} -vw "${LSOF_GREP}" | ${EGREPBINARY} -v '/dev/zero|/\[aio\]' | ${AWKBINARY} '{ if ($5=="REG") { printf "%s(%s)\n", $10, $1 } }' | ${GREPBINARY} -v "^$" | ${SORTBINARY} -u) if [ ! -z "${FIND}" ]; then LogText "Result: found one or more files which are deleted, but still in use" for I in ${FIND}; do