Skip to main content

Protocol CIFS

Pack Assets​

Templates​

The Centreon Pack CIFS/SMB brings a host template:

  • App-Protocol-Cifs-custom

It brings the following Service Templates:

Service AliasService TemplateDefaultDiscovery
ConnectionApp-Protocol-Cifs-ConnectionX
Files-CountApp-Protocol-Cifs-Files-Count
Files-DateApp-Protocol-Cifs-Files-Date
Files-SizeApp-Protocol-Cifs-Files-Size
ScenarioApp-Protocol-Cifs-Scenario

Collected metrics & status​

Metric nameDescriptionUnit
connection statusConnection status
connection.time.secondsConnection time to established the cifs sessions

Prerequisites​

To monitor your CIFS server, you can use username authentication.

Setup​

  1. Install the Centreon package on every Centreon poller expected to monitor Protocol CIFS resources:
yum install centreon-plugin-Applications-Protocol-Cifs
  1. On the Centreon web interface, install the Protocol CIFS Centreon Pack on the Configuration > Monitoring Connector Manager page.

Configuration​

Host​

  • Log into Centreon and add a new host through Configuration > Hosts.
  • Fill the Name, Alias & IP Address / DNS fields according to your Protocol CIFS server settings.
  • Apply the App-Protocol-Cifs-custom template to the host.
  • Once the template is applied, fill in the corresponding macros. Some macros are mandatory.
MandatoryNameDescription
PROTOCOLCIFSUSERNAMEUsername
PROTOCOLCIFSPASSWORDPassword
PROTOCOLCIFSTIMEOUTTimeout (Default: 30)
PROTOCOLCIFSEXTRAOPTIONSAny extra option you may want to add to the command (eg. a --verbose flag)

How to check in the CLI that the configuration is OK and what are the main options for?​

Once the plugin is installed, log into your Centreon poller's CLI using the centreon-engine user account (su - centreon-engine) and test the plugin by running the following command:

/usr/lib/centreon/plugins/centreon_protocol_cifs.pl \
--plugin=apps::protocols::cifs::plugin \
--mode=connection \
--hostname='10.0.0.1' \
--cifs-username='my-username' \
--cifs-password='my-password' \
--directory='/test' \
--verbose

The expected command output is shown below:

OK: authentication succeeded - connection time: 1.372s | 'connection.time.seconds'=1.372s;;;0;

All available options for a given mode can be displayed by adding the --help parameter to the command:

/usr/lib/centreon/plugins/centreon_protocol_cifs.pl \
--plugin=apps::protocols::cifs::plugin \
--mode=connection \
--help

All available modes can be displayed by adding the --list-mode parameter to the command:

/usr/lib/centreon/plugins/centreon_protocol_cifs.pl \
--plugin=apps::protocols::cifs::plugin \
--list-mode

Troubleshooting​

Please find the troubleshooting documentation for plugins in this chapter.