Hello,Is it possible to check if an iSCSI link is mounted on a CentOS server from Centreon?Thank you for your help.
hello
short answer : no, not outside of the box.
longer answer : it depends.
it depends on what type of iscsi you have, software, or hardware hba, it will be vendor dependant (whatever iscsi software or hardware you use… so many option I can’t begin to list them here)
basically iscsi will add devices to your os, that device is either present or absent, and it can be mounted as a partition (or not mounted because reasons)
you could do a filesystem check, or check the presence of a file, or create a command/script depedant on your iscsi vendor
sorry to not be more helpful, try to see on your centos how you can see if your iscsi link is correctly working, if you can find a command line, with a bit of cleanup around the output, this could be a custom check that you can include in your monitoring
Hello Christophe,Actually, I'm setting up an iSCSI link on the CentOS servers that points to a Qnap NAS. It always has the same directory structure.Thanks for the idea of testing for the presence of a "type" folder.Do you have the command syntax?Best regards,
if you use the linux nrpe check there are templates for that

if you use snmp, you can’t do that, but you can check the disk usage, that could be a way to see if the file system is mounted

the final option is check by ssh, Linux SSH | Centreon Documentation but I don’t use it personnaly, but there is file-size/file-date command
I can’t really give you examples
there is also a generic “check by ssh” that will let you pass a command and get the return, a simple “ls /yourpath/yourfile”
ls will “exit 0” if the file is present, and “exit 2” if the file is not present
Thanks for the information, Christophe. I installed the model indicated, here is what I get:

but the resource status returns me the message: command execution failed
you probably need to install the plugin on the poller, that errror is usual when yuou didn”t install the plugin, and just the connector
and configure the nrpe agent on the host you need to monitor
there are documentation here on how to use connector/plugin Plugin Packs | Centreon Documentation
and here is a doc on the specific connector nrpe4 Linux NRPE4 | Centreon Documentation (there are multiple plugin version)
Reply
Login to the community
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.