Closed paydaycay closed 4 years ago
Parameters like CPU usage is retrieved using standard built-in native functions of Zabbix. That's why there's no need to specify them inside UserParameter. What version of Zabbix agent and OS do you use? Do you use it in some special potentially limited environment like Raspberry PI?
Oops sorry, php-fpm.cpu works but I can't get a lot of other values (php-fpm.slow_requests, php-fpm.active_processes, php-fpm.accepted_conn, php-fpm.idle_processes, php-fpm.listen_queue, etc...). Zabbix agent version is 4.4.9 and OS is Ubuntu 16.04. I don't use any limited environment.
Did you test what data actually is reported by PHP? Can you open the status page from the server?
Yes here is what I retrieve from status page :
curl -L 127.0.0.1/php-fpm-status pool: www process manager: dynamic start time: 18/Jun/2020:02:00:13 +0200 start since: 23873 accepted conn: 17289 listen queue: 0 max listen queue: 0 listen queue len: 0 idle processes: 2 active processes: 1 total processes: 3 max active processes: 4 max children reached: 0 slow requests: 0
What I retrieve from zabbix_get :
zabbix_get -s IP_HOST_FPM -k php-fpm.active_processes[/run/php/php7.2-fpm.sock] ZBX_NOTSUPPORTED: Unsupported item key.
Here what I have in Zabbix for my pool :
And for PHP-FPM :
Thank you for your info! I will come back to you soon.
ok @rvalitov Thank you for your help :)
I published a new release, can you test it please? You need to update the file userparameter_php_fpm.conf
.
There was a problem with sudo access rights to the status script #32. I also updated the the Wiki, see section https://github.com/rvalitov/zabbix-php-fpm/wiki/Installation#13-root-privileges Please follow the instructions there. Thank you!
/remind me this issue in 10 days
@rvalitov set a reminder for Jul 11th 2020
:wave: @rvalitov, this issue
Hi, I succeeded to install everything thanks to your awesome explanations in the Wiki.
Unfortunatly, I can't retrieve a lot of php-fpm data like php-fpm.cpu, php-fpm.max_active_processes, etc..
If I try to run it with zabbix_get I can see it's an unsupported item key.
If we take a look in the userparameter_php_fpm.conf, we can see that there isn't any UserParameter for all theses commands.
So, how do you make it work ? Did I miss something ?