[Apan-users] RE: Apan-users digest, Vol 1 #247 - 2 msgs
Status: Beta
Brought to you by:
useless
|
From: Greg K. <wg...@ci...> - 2005-07-21 04:55:06
|
> Date: Wed, 20 Jul 2005 08:26:31 +0100 (BST)
> From: Michael Carel <kir...@ya...>
> To: apa...@li...
> Subject: [Apan-users] Missing RRD Graph Link to services
>=20
> Hi to all;
>=20
> Im just new here in APAN, im using nagios-2.0b3, i've
> installed APAN as documented but unable to performed
> the "small hacks" part of nagios to status.c, it seems
> the new nagios version has a different code than what
> is documented in APAN, but still tries to continued
> installing APAN. I have a missing rrs graph link to
> "Services Detail" where i used to add APAN service to
> a certain host. Below is my sample config using
> "locahost" and "PING" as a service:
>=20
> cgi.cfg:
> #APAN EXTINFOFILE
> xedtemplate_config_file=3D/usr/local/nagios/etc/servicextinfo-apan
>=20
> servicextinfo-apan:
> # Localhost PING Service
> define serviceextinfo {
> host_name localhost
> service_description PING
> notes_url
> /nagios/cgi-bin/apan-sql.cgi?host=3Dlocalhost&service=3DPING
> icon_image graph.png
> icon_image_alt View Apan-graphs
> }
>=20
> commandcheck.cfg:
> define command{
> command_name check_ping
> command_line $USER1$/check_ping -H
> $HOSTADDRESS$ -w $ARG1$ -c $ARG2$ -p
> 5
> }
>=20
> define command {
> command_name apan-sql
> command_line
> /usr/local/nagios/apan-sql/apan-sql.sh $ARG1$
> $HOSTNAME$ "
> $SERVICEDESC$" $TIMET$ $ARG2$ $ARG3$
> }
>=20
> define service{
> use
> generic-service ; Name of service
> template to use
> host_name localhost
> service_description PING
> is_volatile 0
> check_period 24x7
> max_check_attempts 4
> normal_check_interval 5
> retry_check_interval 1
> contact_groups admins
> notification_interval 960
> notification_period 24x7
> check_command
> apan-sql!ping!100.0,20%!500.0,60%
> }
>=20
> RRDs was successfully created under $NagiosDir/rrd..
> Services was also created in mysql DB via apancfg.
>=20
> Is there something i missed? logs and nagios show
> successfull ping checks via apan, but i dont see the
> rrd graph links to see the rrd graphs.
>=20
> Any idea why?
>=20
> Thanks in advance for the help..
>=20
>=20
>=20
> Mike
>=20
>=20
>=20
>=20
> Send instant messages to your online friends =
http://uk.messenger.yahoo.com
Hi Mike:
I'd recommend the following:
1. verify servicextinfo-apan file is in correct/consistent location. =
Both
apan config directives and cgi.cfg directives should point to the same =
file.
i.e.
apanconf.defs:=20
# File with Apan's serviceextinfo-definitions
EXTINFOFILE=3D<whatever>/servicextinfo-apan.cfg
And cgi.cfg:=20
xedtemplate_config_file=3D<whatever>/servicextinfo-apan.cfg
2. Make sure user nagios can read said file
chown -R :nagios <whatever>
chmod -R g=3Drwx <whatever>
3. If the apanconf.def location was different than the cgi.cfg location,
make sure the file generated by apan is in the true location. Restart =
Nagios
if you had to change any of these settings.
Good luck!
Regards,
Greg King
|