Difficulty configuring CIFS monitoring

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

Difficulty configuring CIFS monitoring

Post by dlukinski »

Hello Nagios support

We are trying to monitor filesize for the file, located on the CIFS volume

- with this kind of path:
\\XYZ-cifs01-biz\XYZ-FS-PROD\XYZ\In Production\Apps\Service Management Reporting\Asset Analytics\

------------------------------------------------------------------------------------------------------------------------

CIFS Wizard does not work:

check_mountpoint!\XYZ-FS-PROD\XYZ\In Production\Apps\Service Management Reporting\Asset Analytics -i

Usage: check_mountpoints.sh [-m FILE] $mountpoint [$mountpoint2 ...]
Usage: check_mountpoints.sh -h,--help
Options:
-m FILE Use this mtab instead (default: /proc/mounts)
-f FILE Use this fstab instead (default: /etc/fstab)
-N NUMBER FS Field number in fstab (default: 3)
-M NUMBER Mount Field number in fstab (default: 2)
-T SECONDS Responsetime at which an NFS is declared as staled (default: 3)
-L Allow softlinks to be accepted instead of mount points
-i Ignore fstab. Do not fail just because mount is not in fstab. (default: unset)
-a Autoselect mounts from fstab (default: unset)
-A Autoselect from fstab. Return OK if no mounts found. (default: unset)
-w Writetest. Touch file $mountpoint/.mount_test_from_$(hostname) (default: unset)
MOUNTPOINTS list of mountpoints to check. Ignored when -a is given

-------------------------------------------------------------------------------------------------------

What is best way to make this happen?

Thanks,
Dimitri
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Difficulty configuring CIFS monitoring

Post by tgriep »

Try changing the path from backslashes to forward slashes like this for the check and add single quotes because of the space in the name.

Code: Select all

'/XYZ-FS-PROD/XYZ/In Production/Apps/Service Management Reporting/Asset Analytics/'
Also, is the CIF mounted on the nagios system?
The plugin checks to see if the CIF is mounted in the local system.

If it is a remote server, you may have to find another plugin.
Be sure to check out our Knowledgebase for helpful articles and solutions!
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

Re: Difficulty configuring CIFS monitoring

Post by dlukinski »

tgriep wrote:Try changing the path from backslashes to forward slashes like this for the check and add single quotes because of the space in the name.

Code: Select all

'/XYZ-FS-PROD/XYZ/In Production/Apps/Service Management Reporting/Asset Analytics/'
Also, is the CIF mounted on the nagios system?
The plugin checks to see if the CIF is mounted in the local system.

If it is a remote server, you may have to find another plugin.
So if we want to monitor CIFS/NFS content, it should always be mounted to Nagios locally?
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Difficulty configuring CIFS monitoring

Post by tgriep »

To use that plugin, yes it will have to be mounted on the Nagios server.
Also, that plugin does not look for a size of a file either so that plugin will not works for that either.
Be sure to check out our Knowledgebase for helpful articles and solutions!
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

Re: Difficulty configuring CIFS monitoring

Post by dlukinski »

tgriep wrote:To use that plugin, yes it will have to be mounted on the Nagios server.
Also, that plugin does not look for a size of a file either so that plugin will not works for that either.
If it does not, how could I check for File sizes and counts on CIFS / NFS shares with Nagios?
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Difficulty configuring CIFS monitoring

Post by tgriep »

I found some plugins on the Exchange site that may work for you. Take a look at them to see if they will.
https://exchange.nagios.org/directory/P ... es/details
https://exchange.nagios.org/directory/P ... le/details

There might be others but those 2 look closest to what you are looking for.
Be sure to check out our Knowledgebase for helpful articles and solutions!
dlukinski
Posts: 1130
Joined: Tue Oct 06, 2015 9:42 am

Re: Difficulty configuring CIFS monitoring

Post by dlukinski »

tgriep wrote:I found some plugins on the Exchange site that may work for you. Take a look at them to see if they will.
https://exchange.nagios.org/directory/P ... es/details
https://exchange.nagios.org/directory/P ... le/details

There might be others but those 2 look closest to what you are looking for.
Would this be a Nagios-side plugin?
- so that we still mount CIFS and use the plugin against the mounted volume?
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Difficulty configuring CIFS monitoring

Post by tgriep »

I did a very quick look them and the Plugins run on the Nagios server but they do not have to be mounted on the Nagios server.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked