I want to set Nagios (on my Debian) to verify a SharePoint server is up. I already tried to use cURL but it didn’t worked for some issue that I don’t know so I decided to change the way I’ll verify that service.
It’s simple in theory, I just have to make a script to send an request (http or https, doesn’t matter) and check the response, if is 200 for successful or 40x if not (ok at this point).
So I have to use telnet or any ftp service to do that or I can use another feature/tool for that.
With telnet I’am having problem with 400 error. SharePoint returns this error when server is up or down, so I don’t work for me.
Any ideas??
I done my own way to check if SharePoint is UP or DOWN. Please pay attention that this script just checks the service status, nothing more like user permissions or whatever.
Perl script:
In case you got this exception when you run the script:
this article may help you as it helped me:
http://help.directadmin.com/item.php?id=274
So in Nagios
commands.cfgfile you’ll declare the command this way:command_line /usr/local/nagios/libexec/check_sharepoint.pl -h $HOSTADDRESS$Where
$HOSTADDRESSis the host IP variable in Nagios scope.Remember to
chmod +xon the file. I know you will…