URL content monitoring

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
keerthi.seetharaman
Posts: 92
Joined: Thu Jan 11, 2018 7:55 am

URL content monitoring

Post by keerthi.seetharaman »

Hello Team,
We are using your plugin check_http for our url monitoring via NagiosXI. 
We have a situation here, we have got a new request in which if the pattern “Test Failed” will appear in the content of the URL – the error should be generated. 
We tried by using -s and -R but no luck. 
By using -s“Test Failed” it is searching for the content and throwing Critical state if not found. But we want a reverse monitoring that if this pattern is found then it should throw Critical error.
Please help us for the same.
Do let me know, in case you need some more info.
Thanks in Advance.
Regards,
Keerthi Prashanth S
Thanks & Regards,
Keerthi Prashanth Seetharaman
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: URL content monitoring

Post by cdienger »

The -R option can be used to specifiy a regex string and --invert-regex used to return CRITICAL if found:

/usr/local/nagios/libexec/check_http -H <hostname> -R "Test Failed" --invert-regex
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
keerthi.seetharaman
Posts: 92
Joined: Thu Jan 11, 2018 7:55 am

Re: URL content monitoring

Post by keerthi.seetharaman »

Thanks for your quick help.

Please go ahead and close this case.
Thanks & Regards,
Keerthi Prashanth Seetharaman
Locked