#zbx_redis_template
Zabbix template for Redis (python)
You can monitor your redis in zabbix agent mode.
In zabbix agent mode, zabbix will periodically send request to an agent for every parameter, and agent will answer it.
In trap-message mode, script will be periodically accumulate redis's parameters and will send it to zabbix as a one message.
If you planning to capture many redis parameters and do it often. I would recomend to use trap-message mode.
-
Put
zbx_redis.conf
into yourzabbix_agentd.conf
config subdirectory (like:/etc/zabbix/zabbix_agentd.d/
). -
Change script name and redis password in
zbx_redis.conf
to usezbx_redis_stats.py
if need it . Redis server params can be passed to the python script as arguments e.g.:
zbx_redis_stats.py -p 6379 -a password $1 $2 $3
-
Put
zbx_redis_stats.py
into yourzabbix_agentd.conf
config subdirectory (like:/etc/zabbix/script/redis/
). -
Change paths in
zbx_redis.conf
if need it. -
In working dir (
/etc/zabbix/script/redis/
) do:
For use python verson script:
pip install redis
pip install psutil
chmod +x zbx_redis_stats.py
- Import
zbx_export_template.xml
into zabbix in Tepmplate section web gui.
-
fix get dbsize bug
-
add get redis vmsize and vmsize ratio