Build precise queries to find exactly what you need
Press ESC to close
Nagios World Conference 2026: Sept. 14-17 in St. Paul, MN | Learn More
On SLES 10 with Bash 3.1.17 the script needs some minor modifications that it works.
I got these errors:
line 299: let: FILE_AGE = 1335536854 – : syntax error: operand expected (error token is ” “) line 300: let: FILE_AGE_UNITS = / 3600: syntax error: operand expected (error token is “/ 3600”) line 303: [: -gt: unary operator expected line 306: [: -gt: unary operator expected
How to fix it ————– Line 294 from: st_ctime=`stat –printf=%Y ${next_filepath}`
Line 294 to: st_ctime=`stat –format=%Y ${next_filepath}`
Line 303 from: if [ $FILE_AGE -gt $MAX_CRIT_AGE ]; then
Line 303 to: if [[ $FILE_AGE -gt $MAX_CRIT_AGE ]]; then
Line 306 from: elif [ $FILE_AGE -gt $MAX_WARN_AGE ]; then
Line 306 to: elif [[ $FILE_AGE -gt $MAX_WARN_AGE ]]; then
Besides that nice work!