Subject: A couple of questions

From: <[email-masked]>
Date: Thu, 6 Jul 2006 12:38:51 +0200

Hi there,

We are in the process of setting up Argus for sharp usage to be used within a team of support-personell.

However, we have a bunch of questions.

A) Is it possible to configure Argus to not send alarms during the "sleeping hours" of the day? I understand it can be solved by a custom notify-method, but is there some more generic way to handle this, or an existing written method to filter this?

B) Is it possible to use external authentication sources? (LDAP, PAM, .htaccess)

C) I would like to ask my MySQL-servers if replication is up. The way I normally do this is by issuing the SQL query "SHOW SLAVE STATUS;". This feeds me a table back, where I have to check to columns for the value "Yes". Can I somehow select columns from a result in a SQL query?

Regards
/ Ulrik

---

From: Jeremy Kister <[email-masked]>
Date: Thu, 06 Jul 2006 14:40:00 -0400

On 7/6/2006 6:38 AM, [email-masked] wrote:
> A) Is it possible to configure Argus to not send alarms during the
 > "sleeping hours" of the day? I understand it can be solved by a
 > custom notify-method, but is there some more generic way to handle
 > this, or an existing written method to filter this?

Besides setting an override cron, I don't think so.

Easiest way may be to have a cron that redirects your destination 
mailbox to the bitbucket.  So if argus sends notifies to 
[email-masked], you could have a cron that just throws away 
that mail during certain hours.

> B) Is it possible to use external authentication sources? (LDAP,

Several people have written plugins; argus is easily configurable to 
authenticate against any mechanism.  See the contrib/ directory in the 
argus tarball (argus_pam.tar, web_auth_*.pl)

> C) I would like to ask my MySQL-servers if replication is up. The
 > way I normally do this is by issuing the SQL query "SHOW SLAVE
 > STATUS;". This feeds me a table back, where I have to check to
 > columns for the value "Yes". Can I somehow select columns from a
 > result in a SQL query?

Notice the second service:

Group "mysql-2" {
	Service DB {
		dsn:	DBI:mysql:host=mysql-2;database=dns
		expect:	value
		pass:	pass
		sql:	SELECT field FROM table WHERE key = "val"
		user:	user
	}
	Service DB {
		dsn:	DBI:mysql:host=mysql-2
		expect:	Yes Yes
		label:	slave_status
		pass:	pass
		rowfmt:	%{Slave_IO_Running} %{Slave_SQL_Running}
		sql:	show slave status
		uname:	Status
		user:	user
	}
}

-- 

Jeremy Kister
http://jeremy.kister.net./

---

From: [email-masked]
Date: Thu, 6 Jul 2006 12:42:11 -0700

> that mail during certain hours.

Even easier is to have cron set an override.  You can use something like
the following.  It can be placed inside a service or a group.

        cron "0 13 * * 5" {
            func: override
            text: This server is overridden because there is no reason to
check non-production boxes on evenings and weekends.  The current override
is for the weekend.
            mode: manual
            expires: 219600
            quiet: no
        }

This  message,together  with  any  attachments, is
intended only for the use of the individual or entity
to which it is addressed. It may contain information
that is confidential and prohibited from disclosure.
If you are not the intended recipient, you are hereby
notified that  any dissemination  or copying of this
message or any attachment is strictly prohibited. If
you have received this message in error, please notify
the  original  sender immediately by telephone or by
return e-mail and delete this message, along with any
attachments, from your computer.  Thank you.