IT Knowledge/HAProxy
Testing Your HAProxy Config
Seok.
2023. 8. 10. 22:10
반응형
For the impatient, here’s a simple command to test a configuration file:
$ haproxy -f /path/to/haproxy.cfg -c
The flag '-c', enables “check mode” and is the flag that tells HAProxy to test, without actually starting or restarting HAProxy
Testing a Running Proxy’s Config
Testing a throwaway config is one thing, but when you make a change to a running service’s configuration file, how should you test?
The procedure is exactly the same:
$ haproxy -f /etc/haproxy/haproxy.cfg -c
Configuration file is valid
This will have no effect on the running HAProxy process, as long as you have the check mode (-c) flag in place.
출처: <https://www.haproxy.com/blog/testing-your-haproxy-configuration/>
반응형