MOON
Server: Apache/2.2.31 (Unix) mod_ssl/2.2.31 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4
System: Linux csr818.wilogic.com 2.6.18-419.el5xen #1 SMP Fri Feb 24 22:50:37 UTC 2017 x86_64
User: digitals (531)
PHP: 5.4.45
Disabled: NONE
Upload Files
File: //usr/share/munin/plugins/env
#!/usr/bin/perl -w
# -*- perl -*-

=head1 NAME

env - Plugin for testing enviroment setting.

=head1 CONFIGURATION

No configuration

=head1 AUTHOR

Copyright (C) 2004 Dagfinn Ilmari Mannsaaker

=head1 LICENSE

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; version 2 dated June, 1991.

This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA.

=head1 MAGIC MARKERS

 #%# family=test

=cut

use strict;

my @keys = grep /^munin/, keys %ENV;

if ($ARGV[0] and $ARGV[0] eq 'config') {
    print "graph_title Environment variables\n";
    print "graph no\n";
    print "count.label count\n";
    for my $key (@keys) {
	print "$key.label $key length\n";
    }
    exit 0;
}

print "count.value ", scalar(@keys), "\n";

for my $key (@keys) {
    print "$key.value ", length($ENV{$key}), "\n";
    print "$key.extinfo $ENV{$key}\n";
}