> On Tuesday 19 November 2002 16:20, Philippe Trolliet wrote:
> > hello,
> > the first thing i want to know is if i understood the principle of
> > dependencies correctly.
> > if a service and its dependency fails, then mon only sends an
> alert of the
> > dependency. is that right?
>
> dep_behavior a
> "don't send alert if dependency failed"
>
> dep_behavior m
> "don't even run monitor if dep. failed"
>
> > i have the problem, that all dependencies of the service i am
> testing are
> > successfull and the service itself fails. but mon doesn�t send
> any alert. i
> > also have multiple dependencies in my mon.cf and i don�t get any error.
> > i�m using mon.cgi as webinterface. it shows me the failed
> service and says
> > that no alerts were send.
>
> does it work if you remove all dependencies?
> (check alertafter, numalerts & friends...)

yes. when i explicitly specifiy all dependencies it works too.
the first variant i tried was the following:

watch a
        service a1
        description ping
        interval 5m
        monitor fping.monitor
        period wd{Mon-Sun} hr{2} min{10-59}, wd{Mon-Sun} hr{3-1} min{0-59}
            alert mail.alert someone@somewhere
            alertevery 1h
        service a2
        description dns
        interval 5m
        monitor dns.monitor
        period wd{Mon-Sun} hr{2} min{10-59}, wd{Mon-Sun} hr{3-1} min{0-59}
            alert mail.alert someone@somewhere
            alertevery 1h

watch b
        service b1
        description ping
        interval 5m
        monitor fping.monitor
          depend a:a1
          dep_behavior a
        period wd{Mon-Sun} hr{2} min{10-59}, wd{Mon-Sun} hr{3-1} min{0-59}
            alert mail.alert someone@somewhere
            alertevery 1h

watch c
        service c1
        description ping
        interval 5m
        monitor fping.monitor
          depend b:b1
          dep_behavior a
        period wd{Mon-Sun} hr{2} min{10-59}, wd{Mon-Sun} hr{3-1} min{0-59}
            alert mail.alert someone@somewhere
            alertevery 1h

watch d
        service d1
        description ping
        interval 5m
        monitor fping.monitor
          depend b:b1 and a:a2
          dep_behavior a
        period wd{Mon-Sun} hr{2} min{10-59}, wd{Mon-Sun} hr{3-1} min{0-59}
            alert mail.alert someone@somewhere
            alertevery 1h

i only want to send alerts of c:c1 if b:b1 and a:a1 are working and no
alerts if they fail. but that didn�t work.
i had to remove the dependecy in b:b1, then it worked. the same for d:d1. i
removed the dependencies in all parent services. the it worked.

>
> > i have something like a hierarchy of dependencies. e.g. if the router
> > fails, only send alerts of the router and not alerts of hosts
> behind it. do
> > i have to order them correctly? the first in the hierarchy is first in
> > mon.cf and the last...?
>
> no
>

any idea?

>
> neither...>;->
>
> Piero

philippe

_______________________________________________
mon mailing list
[EMAIL PROTECTED]
http://linux.kernel.org/mailman/listinfo/mon

Reply via email to