Hi,
I have configure check_winfile plugin to check some directory, for example as below.
check_files = scripts\check_winfile.exe --target "C:\dments" --filter "name match \.fail$" --warn 1 --critical 2
How to force the plugin to only check the contents of this folder without subdirectories. Because now checks several thousand files in the subdirectories instead of just a few in the main folder.
I appreciate any idea
Regards,
Edward
check_winfile - how to disable subdirectories checking
Re: check_winfile - how to disable subdirectories checking
You will need to specify the files to check directly, or just the handful of sub-directories that you actually want to check. From the plugin help:
So I would set the target to just the sub-directories you want searched.--target file/directory[,file/directory]...]] [[--target ...] ... ]
This option specifies targets to check. A target can be a simple file or a recursive list of files in a directory. You can specify several comma separated targets for one --target option, as well as several --target options. At least one is required.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Re: check_winfile - how to disable subdirectories checking
I'm not sure that i understand you right. I see this help explanation earlier but i don't see answer there.
I have location C:\dments and inside about 30-40 files which i wanna check. But in C:\dments is also about 20 folders with 20-30k not important files and it's checked also.
Is It to check files in folder dments, only files without subdirectories?
I have location C:\dments and inside about 30-40 files which i wanna check. But in C:\dments is also about 20 folders with 20-30k not important files and it's checked also.
Is It to check files in folder dments, only files without subdirectories?
-
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: check_winfile - how to disable subdirectories checking
As mentioned you will need to provide a direct path to each file if you do not want it to check everything in the directory, you can add additional files, by providing their paths in a coma separated list as the help output suggests. Give that a shot and let us know. If you are still having troubles post how you are manually running the command, including the directories in a coma separated list as I noted.
Re: check_winfile - how to disable subdirectories checking
I just configure CheckFiles using nrpe and I thing this is what I want http://www.nsclient.org/nscp/wiki/CheckDisk/CheckFiles
Thanks for help
Thanks for help
Re: check_winfile - how to disable subdirectories checking
It should be real simple to setup as this is a built-in nsclient check.edwardzg wrote: I thing this is what I want http://www.nsclient.org/nscp/wiki/CheckDisk/CheckFiles
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.