Munin + bind9 (Debian) nem mukodik vagyis nincsennek grafikonok ... [Megoldva]

Fórumok

Debian Etch volt a gepen azt frisitettem azota mar ... A gondolm az hogy a munin -ban a bind9 rol nem keszulnek el a grafikak ... mar probaltam mindent de valahogy megakadtam a tudasommal ...

http://blog.gnist.org/article.php?story=MonitorBindWithMunin&mode=print

szerinte allitorttam be a dolgokat de

http://localhost/munin/localdomain/localhost.localdomain-bind9.html

itt a felsonel megcsinalja a grafikat de a diagram teljessen ures, mig az alasonal

http://localhost/munin/localdomain/localhost.localdomain-bind9_rndc.html

meg a grafikakat sem csinalja meg...

A bind9 szerintem rendesen megcsinalj a naplofajlokat... Ha valaki tud segiteni akkor irja meg hogy milyen adatokat kozoljek meg ha ennyi nem eleg ...

A munin-node.log tartalmat idezem itt be gondolom ez itt eppen a gondomrol beszel csak nemigazan ertem hogy mit is jelent ...

Process Backgrounded
2009/03/10-16:19:15 MyPackage (type Net::Server::Fork) starting! pid(27520)
Binding to TCP port 4949 on host *
Warning: Unknown config option in "/etc/munin/plugin-conf.d/munin-node" under "[sensors*]": env.ignore_volt2 at /usr/sbin/munin-node line 702, line 69.
Warning: Unknown config option in "/etc/munin/plugin-conf.d/munin-node" under "[sensors*]": env.ignore_volt7 at /usr/sbin/munin-node line 702, line 70.
Use of uninitialized value $fields[1] in string eq at /etc/munin/plugins/mysql_isam_space_localhost line 215, line 1.
Use of uninitialized value $index{"Data_length"} in array element at /etc/munin/plugins/mysql_isam_space_localhost line 221, line 1.
Argument "Database: information_schema\n" isn't numeric in multiplication (*) at /etc/munin/plugins/mysql_isam_space_localhost line 221, line 1.
Use of uninitialized value $index{"Max_data_length"} in array element at /etc/munin/plugins/mysql_isam_space_localhost line 221, line 1.
Illegal division by zero at /etc/munin/plugins/mysql_isam_space_localhost line 221, line 1.
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:19:21 Server closing!
Process Backgrounded
2009/03/10-16:19:22 MyPackage (type Net::Server::Fork) starting! pid(27729)
Binding to TCP port 4949 on host *
Warning: Unknown config option in "/etc/munin/plugin-conf.d/munin-node" under "[sensors*]": env.ignore_volt2 at /usr/sbin/munin-node line 702, line 69.
Warning: Unknown config option in "/etc/munin/plugin-conf.d/munin-node" under "[sensors*]": env.ignore_volt7 at /usr/sbin/munin-node line 702, line 70.
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:20:02 CONNECT TCP Peer: "127.0.0.1:40584" Local: "127.0.0.1:4949"
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:20:02 Plugin "bind9" exited with status 512. --graph_title DNS Queries by type
graph_vlabel Queries / ${graph_period}
query_other.label Other
query_other.type DERIVE
query_other.min 0
query_other.draw AREA
--
Use of uninitialized value $IN{"[Common]"} in concatenation (.) or string at /etc/munin/plugins/bind9_rndc line 80.
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:20:07 Plugin "bind9" exited with status 512. ----
2009/03/10-16:25:03 CONNECT TCP Peer: "127.0.0.1:57121" Local: "127.0.0.1:4949"
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:25:03 Plugin "bind9" exited with status 512. --graph_title DNS Queries by type
graph_vlabel Queries / ${graph_period}
query_other.label Other
query_other.type DERIVE
query_other.min 0
query_other.draw AREA
--
Use of uninitialized value $IN{"[Common]"} in concatenation (.) or string at /etc/munin/plugins/bind9_rndc line 80.
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:25:09 Plugin "bind9" exited with status 512. ----
2009/03/10-16:30:02 CONNECT TCP Peer: "127.0.0.1:43075" Local: "127.0.0.1:4949"
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:30:03 Plugin "bind9" exited with status 512. --graph_title DNS Queries by type
graph_vlabel Queries / ${graph_period}
query_other.label Other
query_other.type DERIVE
query_other.min 0
query_other.draw AREA
--

Hozzászólások

Not Found

The requested URL /munin/localdomain/localhost.localdomain-bind9.html was not found on this server.

Itt valami mas gond lesz... ROFL

Bocs, de nem, mert a localhost-on kinyissa mindket linket csak az elsonel a grafikonok uressek de maga a kep megvan ...mig a masik linknel a html fajl szinten megvan csak ott a kep sem jelenik meg ...

a log-bol a lejjebb idezett reszlet magyarazza hogy mi a gondom (baris szerintem ...) csak nem igazan ertem ....

Use of uninitialized value $IN{"[Common]"} in concatenation (.) or string at /etc/munin/plugins/bind9_rndc line 80.
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:20:07 Plugin "bind9" exited with status 512. ----
2009/03/10-16:25:03 CONNECT TCP Peer: "127.0.0.1:57121" Local: "127.0.0.1:4949"
Died at /etc/munin/plugins/bind9 line 60.
2009/03/10-16:25:03 Plugin "bind9" exited with status 512. --graph_title DNS Queries by type
graph_vlabel Queries / ${graph_period}
query_other.label Other
query_other.type DERIVE
query_other.min 0
query_other.draw AREA

Ideiglenessen kitettem ezt a 2 linket ahol meglehet nezni a jelenseget ...
megjegyzem hogy a gep nem megy a nap 24 orajaban es igy a lenti 2 link hol mukodik hol nem ...
http://justin.podzone.net/localdomain/localhost.localdomain-bind9.html
http://justin.podzone.net/localdomain/localhost.localdomain-bind9_rndc…

beidezem az egesz fajl, es megjeloltem benne (!!!!!! ez itt a 60 sor !!!!!!) a 60. sort ...



#!/usr/bin/perl -w
#
# Plugin to monitor usage of bind 9 servers
#
# Parameters:
#
# 	logfile      - Location of the query log
# 	statefile    - Where to put temporary statefile.
#
# Contributed by Nicolai Langfeldt
#
# $Log$
# Revision 1.8.2.2  2005/03/07 19:06:13  jimmyo
# sunos/memory repaired (SF#1143610).
#
# Revision 1.8.2.1  2005/02/16 18:03:46  jimmyo
# minor bugfix in generic/bind9.
#
# Revision 1.8  2004/12/10 18:51:43  jimmyo
# linux/apt* has been forced to LANG=C, to get predictable output.
#
# Revision 1.7  2004/12/10 14:21:39  jimmyo
# Patch generic/bind9 to report "unnamed" as "other" (Nicolas Stransky).
#
# Revision 1.6  2004/12/10 10:47:47  jimmyo
# Change name from ${scale} to ${graph_period}, to be more consistent.
#
# Revision 1.5  2004/12/09 22:12:54  jimmyo
# Added "graph_period" option, to make "graph_sums" usable.
#
# Revision 1.4  2004/12/09 20:16:29  jimmyo
# generic/bind9 now handles syslog format as well (by xavier).
#
# Revision 1.3  2004/09/14 20:29:20  jimmyo
# Added statefile parameter.
#
# Revision 1.2  2004/05/14 21:16:46  jimmyo
# "Upped" som plugins from contrib/manual to auto.
#
# Revision 1.1  2004/01/02 18:50:00  jimmyo
# Renamed occurrances of lrrd -> munin
#
# Revision 1.1.1.1  2004/01/02 15:18:07  jimmyo
# Import of LRRD CVS tree after renaming to Munin
#
# Revision 1.1  2003/12/18 21:45:47  jimmyo
# Plugin contributed by Nicolai Langfeldt
#
#
#%# family=contrib

use strict;

my $QUERYLOG=$ENV{logfile} || '/var/log/bind9/query.log';
my $STATEFILE=$ENV{statefile} || '/var/lib/munin/plugin-state/bind9.state';
my $OTHER=0;
my %IN;

sub get_state {
    open(Q,"< $STATEFILE") or die;    !!!!!! ez itt a 60 sor !!!!!!
    while (<Q>) {
        chomp;
        my ($q,$n) = split(/\s+/,$_,2);
        $IN{$q}=$n unless defined($IN{$q});
    }
    close(Q);
}


sub do_stats {
    my $k; 

    open(Q,"< $QUERYLOG") or die "$!";
    while (<Q>) {
	chomp;
	if (/client \d+\.\d+.\d+.\d+\#\d+: query\: \S+ (\w+) (\w+)/) {
	    if ($1 eq 'IN' and $2 !~ /^TYPE/) {
		$IN{$2}++;
	    } else {
		$OTHER++;
	    }
	}
    }
    close(Q);

    get_state;

    open(Q,"> $STATEFILE") or die;
    foreach $k (keys %IN) {
	print "query_$k.value ",$IN{$k},"\n";
	print Q "$k ",$IN{$k},"\n";
    }
    close(Q);

    print "query_other.value ",$OTHER,"\n";
}


sub do_config {
    my $k;

    print "graph_title DNS Queries by type
graph_vlabel Queries / \${graph_period}
query_other.label Other
query_other.type DERIVE
query_other.min 0
query_other.draw AREA
";
    get_state;

    foreach $k (keys %IN) {
	print "query_$k.label $k
query_$k.type DERIVE
query_$k.min 0
query_$k.draw STACK
";
    }
};

if (defined($ARGV[0]) and ($ARGV[0] eq 'config')) {
    do_config;
    exit(0);
}

do_stats;

# vim:syntax=perl

Megjegyzem hogy a /var/lib/munin/plugin-state/bind9.state fajl nem letezik, gondolom azt a munin-nak vagy valami masnak kell letrehoznia, de melyik proginak?

Bocs, de nálam ez a hónap hozzászólása. :)
Arra gondolt sany, hogy a végtelen+1 sor hosszúságú konfigurációs fájlokat a http://pastebin.com/ -on keresztül is meg tudod osztani a nagyközönséggel. Így nem a HUP adatbázisát terheled, nem cseszi szét az oldalt és egyébként ott jobban is látható...

Oppaa, alighanem butabb vagyok mint gondoltam :)

nalam a su - munin ra jelszot ker es en azt nem is tudom sosem kellett beallitanom ... gondolom valahonnan kilehet szedni, de honnan?

A /var/lib/munin/plugin-state/ mappaba a munin tud irni mert abban van par masik fajl amiket a munin hasznal de a bind9.state nincs...

Amennyiben su -kent magaban a pluginokat inditom el ezt kapom:

borg:/etc/munin/plugins#
borg:/etc/munin/plugins# ./bind9
Died at ./bind9 line 60.
borg:/etc/munin/plugins# ./bind9_rndc
query_[View:.value _bind]
Use of uninitialized value $IN{"[Common]"} in concatenation (.) or string at ./bind9_rndc line 80.
query_[Common].value
query_++.value Per

a $STATEFILE erteke a /var/lib/munin/plugin-state/bind9.state ott ez a fajl nem letezik...

Letrehoztam kezzel a hianyzo fajlt, mintha most mukodne a ./bind9 egyelore a grafikon ures de az aljan mar letrehozta az Other, PTR, A, TXT, AAAA cimkeket, a bind9.state fajlban is vannak ertekek, gondolom kis ido elteltevel a grafikonon is megjelenik a rajz ... :)

A masik grafikon, amit a bind9_rndc hoz letre az tovabbra sem mukodik

Igen, koszonom a valaszt valoban az a megoldas...

http://blog.gnist.org/comment.php?mode=display&format=threaded&order=AS…

Ezen a linken talatak alapjan kijavitottam a bind9_rndc fajlt es most ugynezki mintha mukodne! :) Ez a lenti link vegeredmenyben ugynezem ugyanaz mint amit te is irtal csak nekem itt jobban latszott mit is kell javitanom ...

http://munin.projects.linpro.no/ticket/627

Mindenkinek koszonom a segitseget!!!