Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 76018 | Differences between
and this patch

Collapse All | Expand All

(-)Makefile.config (-6 / +6 lines)
Lines 7-16 Link Here
7
#
7
#
8
# the base of the Munin installation.
8
# the base of the Munin installation.
9
# 
9
# 
10
PREFIX     = $(DESTDIR)/opt/munin
10
PREFIX     = $(DESTDIR)/usr
11
11
12
# Where Munin keeps its configurations (server.conf, client.conf, ++)
12
# Where Munin keeps its configurations (server.conf, client.conf, ++)
13
CONFDIR    = $(DESTDIR)/etc/opt/munin
13
CONFDIR    = $(DESTDIR)/etc/munin
14
14
15
# Server only - where to put munin-cron
15
# Server only - where to put munin-cron
16
BINDIR     = $(PREFIX)/bin
16
BINDIR     = $(PREFIX)/bin
Lines 19-38 BINDIR = $(PREFIX)/bin Link Here
19
SBINDIR    = $(PREFIX)/sbin
19
SBINDIR    = $(PREFIX)/sbin
20
20
21
# Where to put text and html documentation
21
# Where to put text and html documentation
22
DOCDIR     = $(PREFIX)/doc
22
DOCDIR     = $(PREFIX)/share/doc
23
23
24
# Where to put man pages
24
# Where to put man pages
25
MANDIR     = $(PREFIX)/man
25
MANDIR     = $(PREFIX)/share/man
26
26
27
# Where to put internal binaries and plugin repository
27
# Where to put internal binaries and plugin repository
28
LIBDIR     = $(PREFIX)/lib
28
LIBDIR     = $(PREFIX)/lib
29
29
30
# Server only - Output directory
30
# Server only - Output directory
31
HTMLDIR    = $(PREFIX)/var/www
31
HTMLDIR    = $(PREFIX)/var/www/localhost/htdocs/munin
32
CGIDIR     = $(HTMLDIR)/cgi
32
CGIDIR     = $(HTMLDIR)/cgi
33
33
34
# Client only - Where to put RRD files and other intenal data
34
# Client only - Where to put RRD files and other intenal data
35
DBDIR      = $(DESTDIR)/var/opt/munin
35
DBDIR      = $(DESTDIR)/var/lib/munin
36
36
37
# Client only - Where plugins should put their states. Must be writable by
37
# Client only - Where plugins should put their states. Must be writable by
38
# group "munin", and should be preserved between reboots
38
# group "munin", and should be preserved between reboots
(-)server/munin-graph.in (-15 / +16 lines)
Lines 649-658 sub process_node { Link Here
649
	    elsif ($global_headers == 1)
649
	    elsif ($global_headers == 1)
650
	    {
650
	    {
651
		push (@rrd, "COMMENT:" . (" " x $max_field_len));
651
		push (@rrd, "COMMENT:" . (" " x $max_field_len));
652
		push (@rrd, "COMMENT: Cur:");
652
                push (@rrd, "COMMENT: Cur\\:");
653
		push (@rrd, "COMMENT:Min:");
653
                push (@rrd, "COMMENT:Min\\:");
654
		push (@rrd, "COMMENT:Avg:");
654
                push (@rrd, "COMMENT:Avg\\:");
655
		push (@rrd, "COMMENT:Max:  \\j");
655
                push (@rrd, "COMMENT:Max\\:  \\j");
656
		$global_headers++;
656
		$global_headers++;
657
	    }
657
	    }
658
658
Lines 725-737 sub process_node { Link Here
725
	    }
725
	    }
726
	    else
726
	    else
727
	    {
727
	    {
728
		push (@rrd, "COMMENT: Cur:") unless $global_headers;
728
		push (@rrd, "COMMENT: Cur\\:") unless $global_headers;
729
		push (@rrd, "GPRINT:c$rrdname:LAST:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, "yes")?"%s":"") . "");
729
		push (@rrd, "GPRINT:c$rrdname:LAST:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, "yes")?"%s":"") . "");
730
		push (@rrd, "COMMENT: Min:") unless $global_headers;
730
		push (@rrd, "COMMENT: Min\\:") unless $global_headers;
731
		push (@rrd, "GPRINT:i$rrdname:MIN:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
731
		push (@rrd, "GPRINT:i$rrdname:MIN:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
732
		push (@rrd, "COMMENT: Avg:") unless $global_headers;
732
		push (@rrd, "COMMENT: Avg\\:") unless $global_headers;
733
		push (@rrd, "GPRINT:g$rrdname:AVERAGE:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
733
		push (@rrd, "GPRINT:g$rrdname:AVERAGE:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
734
		push (@rrd, "COMMENT: Max:") unless $global_headers;
734
		push (@rrd, "COMMENT: Max\\:") unless $global_headers;
735
		push (@rrd, "GPRINT:a$rrdname:MAX:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "\\j");
735
		push (@rrd, "GPRINT:a$rrdname:MAX:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "\\j");
736
		push (@{$total_pos{'min'}}, "i$rrdname");
736
		push (@{$total_pos{'min'}}, "i$rrdname");
737
		push (@{$total_pos{'avg'}}, "g$rrdname");
737
		push (@{$total_pos{'avg'}}, "g$rrdname");
Lines 792-804 sub process_node { Link Here
792
	    
792
	    
793
	    push (@rrd, "CDEF:dpostotal=ipostotal,UN,ipostotal,UNKN,IF");
793
	    push (@rrd, "CDEF:dpostotal=ipostotal,UN,ipostotal,UNKN,IF");
794
	    push (@rrd, "LINE1:dpostotal#000000:" . $node->{client}->{$service}->{graph_total} . (" " x ($max_field_len - length ($node->{client}->{$service}->{graph_total}) + 1)));
794
	    push (@rrd, "LINE1:dpostotal#000000:" . $node->{client}->{$service}->{graph_total} . (" " x ($max_field_len - length ($node->{client}->{$service}->{graph_total}) + 1)));
795
	    push (@rrd, "COMMENT: Cur:") unless $global_headers;
795
	    push (@rrd, "COMMENT: Cur\\:") unless $global_headers;
796
	    push (@rrd, "GPRINT:gpostotal:LAST:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
796
	    push (@rrd, "GPRINT:gpostotal:LAST:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
797
	    push (@rrd, "COMMENT: Min:") unless $global_headers;
797
	    push (@rrd, "COMMENT: Min\\:") unless $global_headers;
798
	    push (@rrd, "GPRINT:ipostotal:MIN:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
798
	    push (@rrd, "GPRINT:ipostotal:MIN:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
799
	    push (@rrd, "COMMENT: Avg:") unless $global_headers;
799
	    push (@rrd, "COMMENT: Avg\\:") unless $global_headers;
800
	    push (@rrd, "GPRINT:gpostotal:AVERAGE:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
800
	    push (@rrd, "GPRINT:gpostotal:AVERAGE:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "");
801
	    push (@rrd, "COMMENT: Max:") unless $global_headers;
801
	    push (@rrd, "COMMENT: Max\\:") unless $global_headers;
802
	    push (@rrd, "GPRINT:apostotal:MAX:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "\\j");
802
	    push (@rrd, "GPRINT:apostotal:MAX:%6.2lf" . (munin_get_bool_val ($node->{client}->{$service}->{graph_scale}, 1)?"%s":"") . "\\j");
803
	}
803
	}
804
804
Lines 810-818 sub process_node { Link Here
810
	    # Do the header (title, vtitle, size, etc...)
810
	    # Do the header (title, vtitle, size, etc...)
811
	    push @complete, @{&get_header ($node, $config, $domain, $name, $service, $time)};
811
	    push @complete, @{&get_header ($node, $config, $domain, $name, $service, $time)};
812
	    push @complete, @rrd;
812
	    push @complete, @rrd;
813
            my $loctime = localtime($lastupdate);
814
            push (@complete, "COMMENT:Last update\\: " . escape($loctime) .  "\\r");
813
815
814
	    push (@complete, "COMMENT:Last update: " . localtime($lastupdate) .  "\\r");
815
	    
816
	    if (time - 300 < $lastupdate)
816
	    if (time - 300 < $lastupdate)
817
	    {
817
	    {
818
		    push @complete, "--end",(int($lastupdate/$resolutions{$time}))*$resolutions{$time};
818
		    push @complete, "--end",(int($lastupdate/$resolutions{$time}))*$resolutions{$time};
Lines 841-847 sub process_node { Link Here
841
			push @rrd_sum, "--end",(int($lastupdate/$resolutions{$time}))*$resolutions{$time};
841
			push @rrd_sum, "--end",(int($lastupdate/$resolutions{$time}))*$resolutions{$time};
842
		}
842
		}
843
		push @rrd_sum, @rrd;
843
		push @rrd_sum, @rrd;
844
		push (@rrd_sum, "COMMENT:Last update: " . localtime($lastupdate) .  "\\r");
844
                my $loctime = localtime($lastupdate);
845
                push (@rrd_sum, "COMMENT:Last update\\: " . escape($loctime) ."\\r");
845
846
846
		my $labelled = 0;
847
		my $labelled = 0;
847
		my @defined = ();
848
		my @defined = ();

Return to bug 76018