[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Check that text does not exist on a page on a name-based virtual host
From: |
Mark Feeney |
Subject: |
Check that text does not exist on a page on a name-based virtual host |
Date: |
Sat, 2 Oct 2010 16:28:13 -0400 |
Greetings.
First: I love monit. Excellent tool. Very simple and effective.
Thanks to all involved.
I have come up with something I can't figure out how to monitor,
though: I want to check that a web page does not contain certain text
and the page is on a name-based virtual host.
This almost works for me:
check host production with address 127.0.0.1
if failed url
http://foo.com/some_page
and content != 'BAD'
then restart
However, it's incorrect for me to use "http://foo.com" since it's a
cluster, so restarting the current server isn't necessarily going to
help.
What I want is something like:
check host production with address 127.0.0.1
if failed url
http://127.0.0.1:9999/some_page
use host header "foo.com" # not real syntax
and content != 'BAD'
then restart
Is there a way to achieve this? proto http and SEND/EXPECT seemed a
possibility, but I'm not sure how to write the EXPECT part.
I'm using monit 4.10.1.
Thanks,
Mark.
- Check that text does not exist on a page on a name-based virtual host,
Mark Feeney <=