Restrict find action to the /tmp mount

This commit is contained in:
Michael Boelen 2016-05-30 19:38:42 +02:00
parent d3202ade5d
commit 751c9734c5
1 changed files with 1 additions and 1 deletions

View File

@ -298,7 +298,7 @@
if [ ${SKIPTEST} -eq 0 ]; then
LogText "Test: Searching for old files in /tmp"
# Search for files only in /tmp, with an access time older than X days
FIND=`find /tmp -type f -atime +${TMP_OLD_DAYS} 2> /dev/null | sed 's/ /!space!/g'`
FIND=`find /tmp -xdev -type f -atime +${TMP_OLD_DAYS} | sed 's/ /!space!/g'`
if [ "${FIND}" = "" ]; then
Display --indent 2 --text "- Checking for old files in /tmp" --result OK --color GREEN
LogText "Result: no files found in /tmp which are older than 3 months"