-
Notifications
You must be signed in to change notification settings - Fork 1
Home
Savan Patel edited this page Mar 27, 2016
·
3 revisions
Welcome to the ha-analyzer wiki!
Parses and mines haproxy logs and stores to mysql where it can be used to analyze performance.
- Copy commands from ha-analyzer.cfg and in config folder to create mysql database and table.
- Create user with password that has read write access to this database and table.
- Supported python version : 2.7
- This has been tested on python 2.7 on ubuntu 14.04 LTS.
- logging :
sudo pip install logging - subprocess :
sudo pip install subprocess - re :
sudo pip install re
- mysql-connector-python :
sudo apt-get install mysql-connector-python
- please setup ha-analyzer config file as per your requirement. Sample config file is in config/ folder(self explanatory)
- make sure that haproxy is configured properly where you get the logs like
Mar 27 12:50:02 localhost haproxy[1346]: 127.0.0.1:41383 [27/Mar/2016:12:50:00.205] http-in hello/localserver 1825/0/0/13/1838 200 151 - - ---- 2/2/0/0/0 0/0 "GET /hello HTTP/1.1"
-
./ha-analyzer.py <configfile>orptyhon ha-analyzer.py <configfile>
-
./shutdown.pyorpython shutdown.py
- Build node js service for dashboard and UI.