HAProxy community

Run Show commands on HAProxy

#1

We have installed HAProxy on ubuntu . Where should i run ‘Show’ commands of HAProxy? how can i get into HAProxy configuration management in ubunt?Please help…

0 Likes

#2

If you have installed it through the package manager such as apt, the configuration file will be at /etc/haproxy/haproxy.cfg.

There is no show command in HAProxy to show you the running configure. You can also run ps -ef | grep -i haproxy command to see from where the running haproxy process is reading its configuration.

1 Like

#3

Thanks… but under this
https://cbonte.github.io/haproxy-dconv/1.7/management.html
I have found some show commands by which i can see the currents states, information, errors and stuffs like that… what are all the commands for? Please help…

0 Likes

#4

You can see all the commands that can be run in the socket interactive mode at https://cbonte.github.io/haproxy-dconv/1.7/management.html#9.3 starting from https://cbonte.github.io/haproxy-dconv/1.7/management.html#9.3-add%20acl

1 Like

#5

Thank you so much for the suggestion… I have added following statements(from above link) in global section and installed ‘socat’
“stats socket /var/run/haproxy.sock mode 600 level admin”
“stats timeout 2m”
I am able to run show commands using “socat /var/run/haproxy.sock stdio” but with this command i can only get output of one command and if i want to run another command i have to again run the stdio command…
but when i run “socat /var/run/haproxy.sock readline” it is throwing below error
'socat [4356] E unknown device/address “readline” 'what could be the reason for this error?Please help

0 Likes