I have this setup where several applications are going through the load balancer (HAproxy) and accessing the MySQL database.
Several applications -> HAproxy -> MySQL database
I would like to know which specific application is accessing the database. When I did a show processlist on the database, it shows the IP of the HAproxy (of course). Then I tried to do lsof on haproxy and mysql database but it didn't help me (or I just don't know to interpret the results properly). And finally I checked the haproxy logs but it didn't show anything.
Thanks.