mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-23 06:35:42 +00:00
- have some dirs
This commit is contained in:
parent
0b089ea777
commit
08346aac58
687 changed files with 0 additions and 0 deletions
27
plugins/nginx/ngnix_memory
Executable file
27
plugins/nginx/ngnix_memory
Executable file
|
@ -0,0 +1,27 @@
|
|||
#!/usr/bin/env perl
|
||||
#
|
||||
# Munin plugin for monitoring Nginx memory usage
|
||||
#
|
||||
# Written by AkyRhO <akyrho@gmail.com> - Please e-mail for support/question/request/feedback
|
||||
#
|
||||
# Last release (v0.1) 2009-04-20
|
||||
# Last release (v0.1a) 2009-04-26 - fix the base to 1024
|
||||
#
|
||||
# ---
|
||||
|
||||
if ( exists $ARGV[0] and $ARGV[0] eq "config" ) {
|
||||
print "graph_title NGINX ram usage\n";
|
||||
print "graph_vlabel ram\n";
|
||||
print "graph_category nginx\n";
|
||||
print "ram.label ram\n";
|
||||
print "graph_args --base 1024\n";
|
||||
} else {
|
||||
my $i = Integer;
|
||||
@cmd = `ps auwx | grep nginx | grep -v grep | grep -v nginx_memory`;
|
||||
|
||||
foreach (@cmd) {
|
||||
@return = split(/ +/, $_);
|
||||
$i += @return[5]*1024;
|
||||
}
|
||||
print "ram.value ".$i."\n";
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue