This repo contains the initial version for a CollectD plugin collecting ProxySQL metrics. Currently this plugin collects only global stats, work needs to be done to also collect connection-pool stats.
- Install
MySQLdb
Python package (tryyum install MySQL-python
orapt install python-mysqldb
) - Place proxysql.py in your CollectD python plugins directory
- Configure the plugin in CollectD
- Restart CollectD
If you don’t already have the Python module loaded, you need to configure it first:
<LoadPlugin python>
Globals true
</LoadPlugin>
<Plugin python>
ModulePath "/path/to/python/modules"
</Plugin>
You should then configure the ProxySQL plugin:
<Plugin python>
Import proxysql
<Module proxysql>
Host localhost
Port 6032 (optional)
User admin
Password xxxx
Verbose true (optional, to enable debugging)
</Module>
</Plugin>