monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: inverse monitoring


From: Martin Pala
Subject: Re: inverse monitoring
Date: Mon, 13 Aug 2007 20:38:02 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.6) Gecko/20070802 Iceape/1.1.4 (Debian-1.1.4-1)

Monit supports actions for both - failure and recovery. The implicit recovery action is to send email, but in general you can use any other monit action as well.

See manual for more details - full syntax:

IF <TEST>
  [[<X>] [TIMES WITHIN] <Y> CYCLES] THEN ACTION
[ELSE IF PASSED
  [[<X>] [TIMES WITHIN] <Y> CYCLES] THEN ACTION]


You can use the 'else if passed ...' part to do what you you want.

Martin



Adrian Schmitt wrote:
Hi,

I would like to monitor that some web pages are not available.
Is there some way to inverse the conditions?

Example (see line 5 "not"):

# 1 check host example.com with address nnn.nnn.nnn.nnn
# 2   if failed icmp type echo with timeout 3 seconds then alert
# 3   if failed port 80 protocol http then alert
# 4   if failed host public.example.com port 80 protocol http then alert
# 5   if NOT failed host internal.example.com port 80 protocol http then alert

In my case this would be very helpful to ensure that
some internal sites are only visible to the LAN and not to the public
internet.

I could not find such functionality in the documentation, did I
overlook something?
When I tried to insert "not" in the config file like in line 5 there
was an error, so I guess this is not the way to do it.

Thank you


--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general




reply via email to

[Prev in Thread] Current Thread [Next in Thread]