Count only files ignore folders

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
sudoo91
Posts: 1
Joined: Wed Dec 09, 2020 12:37 pm

Count only files ignore folders

Post by sudoo91 »

Hi guys,

Can anyone give me an help on this? I want to use the Files Count via nrpe and to have only the possibility to look into files in a specific folder and ignore the subfolders that are inside.

Command line $USER1$/check_nrpe -H host -c check_files -a path='F:\\folder01' pattern=*.* 'warning=count>10' 'critical=count>20' top-syntax='${status}: ${count} files found' 'empty-state=ok' max-depth=1

Output OK: All 3 files are ok

Performance data 'count'=3;10;20

The output is returning me the 3 subfolders that i've inside this "folder01", and the objective is to ignore this 3 subfolders and only look to new files that arrive.

Is this possible with the check_nrpe?
Locked