leprechau / php-fpm-munin-plugins Goto Github PK
View Code? Open in Web Editor NEWMunin plugins for monitoring php-fpm processes and statistics
Munin plugins for monitoring php-fpm processes and statistics
php-fpm status is showing much more information nowadays:
pool: www
process manager: dynamic
start time: 16/Feb/2017:13:57:15 +0100
start since: 354978
accepted conn: 449998
listen queue: 0
max listen queue: 0
listen queue len: 0
idle processes: 5
active processes: 1
total processes: 6
max active processes: 9
max children reached: 0
slow requests: 0
Is it possible to add more of those to the munin plugin?
a value of accepted conn divided by start since would also be interesting (=connections per second).
It's quite easy to make the script run with multiple PHP-FPM pools that have different /status URLs.
phpfpm_check
to (for example) phpfpm_check.primary
$my
/* default config */
$my = array(
'url' => getenv('url') ? getenv('url') : 'http://127.0.0.1:80/status.primary?json',
'fpmbin' => getenv('fpmbin') ? getenv('fpmbin') : 'php-fpm',
'self' => basename($argv[0]),
);
/* Remove pool appendix */
if (($p = strpos($my['self'], '.')) !== false) {
$my['self'] = substr($my['self'], 0, $p);
}
This will strip anything after a point (.) in the filename. This allows to create different symbol links calling the same methods:
ln -s /usr/share/munin/plugins/php-fpm-munin-plugins/phpfpm_check.primary /etc/munin/plugins/phpfpm_average.primary
ln -s /usr/share/munin/plugins/php-fpm-munin-plugins/phpfpm_check.secondary /etc/munin/plugins/phpfpm_average.secondary
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.