HAProxy is a open source, very fast and reliable solution offering high availability, load balancing, and proxying for TCP and HTTP-based applications. It is particularly suited for web sites crawling under very high loads while needing persistence or Layer7 processing.

learn more… | top users | synonyms

0
votes
0answers
3 views

HAproxy 503 Service Unavailable [on hold]

I am following this tutorial to configure HAProxy and Let's Encrypt. The goal is to forward requests to example.com/sensu to a server instance listening on 127.0.0.1:3002. When I visit this url in my ...
0
votes
0answers
7 views

Haproxy performance degradation when backends added [on hold]

We are testing performance of haproxy. It's installed on a physical machine with 40 cores and 256 RAM. OS is Centos 7. During that we noticed a weird thing - the more backend nodes we add, the worse ...
0
votes
1answer
19 views

ftp reverse proxy using haproxy

is it possible to have ftp reverse proxy like http example client >> proxy >> real server i have tried using haproxy but at the end the real ip of the ftp server is exposed not ...
0
votes
0answers
20 views

HAProxy across from two different private networks [on hold]

I have two networks, we shall call them Datacenter 1 (DC1) and Datacenter 2 (DC2). Within DC1, there is a host on a private network (DC1 HostA) that needs to communicate with a host in DC2 (DC2 HostA)...
2
votes
0answers
17 views

HAProxy rate limiting - ban abuser for 30 minutes

I have the following config, that works OK for rate limiting connections. If an abuser is authenticated and he also accesses the defined regex location more than 30 times per minute, rate limiting is ...
0
votes
1answer
13 views

Haproxy ssl passthrough breaks curl requests

I have Haproxy configured in TCP mode to balance between 2 servers and passthrough https connections to them. The problem is that when my frontend is in tcp mode, curl requests can't be proceed ...
0
votes
2answers
28 views

Openshift + HAproxy 503 custom page

I'm using 503 HTTP Status and a coming soon page for maintenance mode. Is there any way to get HAproxy serving server-side generated 503 page instead of the default blank/unavailable page? I'm using ...
1
vote
1answer
11 views

haproxy redirect ip request to ip/path

I have one haproxy node and 3 application server (tomcat) behind it. Users must open http://10.0.0.1 (by IP address) and then be redirected to http://10.0.0.2/app or http://10.0.0.3/app or http://10.0....
0
votes
1answer
12 views

haproxy 503 no server available to handle this request

I'm new to HAproxy and have been following guides to get me started. I think I got the set up I need but when I try to load my web site domain I get a 503 Service Unavailable No server is available ...
1
vote
1answer
14 views

Haproxy http response timeout check

We use haproxy as http load balancer. Sometimes one of our servers stop responding while accepting http connection requests. So stats page displays servers as green "accessible" but our nagios server ...
0
votes
0answers
13 views

Haproxy: how to configure backend to talk with a https server? [duplicate]

We have in our LAN a nginx server configured in https. In front, we have Haproxy with SSL and we need to establish a connection SSL from backend to nginx server. Is it possible to do this? Client -> ...
2
votes
1answer
38 views

what is the default ha-proxy load balance algorithm?

When i was configuring a proxy server which is ha-proxy over Ubuntu server , i forgot to choose a balance option in the haproxy.cnf file ,but steal worked correctly, any one have an idea what ...
0
votes
1answer
18 views

Combining duplications for backend blocks in haproxy.cfg

I have this HAProxy config and as you can see I have many duplicated stuff in backends. Is there a way of getting rid of duplications such as stats? global log 127.0.0.1 local0 log 127.0.0.1 ...
2
votes
2answers
68 views

Software Load Balancer - Forward or Redirect to the backend servers?

I am a web developer, recently a need has been created to use Load Balancer. I am new in this area. I have chosen which LB to use, its not like it matters so much, HAProxy has all the features needed ...
0
votes
1answer
16 views

Increase client timeout for WebSocket connections to certaing URL

On CentOS 7 Linux I successfully use HAProxy 1.5.14 in front of Jetty 9 serving a Wordpress site via FastCGI. It works really well, but for a HTML5/WebSocket game at the same website much higher ...
1
vote
1answer
33 views

Import configuration files in haproxy.cfg

I have almost 200 lines of ACL configurations in haprox.cfg and also contains 150 backends. To remove this configuration complexity, I want to bundle this configuration in separate files and will ...
0
votes
1answer
21 views

System outage when only one of two HAProxy servers is down. Failover doesn't seem to be working

First of all my experience with HAProxy stack is just one day old so I hope my question makes sense. I have 2 HAProxy VMs and 2 Apache VMs (vagrant machines) as follows. 192.168.50.11 HAPROXY VM1 ...
1
vote
1answer
68 views

Preventing Apache from logging HAProxy requests

I have two HAProxy VMs and two Apache VMs (vagrant machines) as follows. 192.168.50.11 HAPROXY VM1 192.168.50.12 HAPROXY VM2 192.168.50.21 APACHE VM1 192.168.50.22 APACHE VM2 The problem I'm having ...
6
votes
2answers
118 views

Can I use HAProxy's new 'capture' feature to save the remote address in a TCP frontend, and use it as the `X-Forwarded-For` header in an HTTP backend?

Using HAProxy 1.6 and a clever hack, I now have an HAProxy tcp mode frontend, that detects if the browser is capable of SNI, and based on that, routes to a strongly ciphered SSL termination backend, ...
2
votes
1answer
26 views

HAProxy TCP Transparent Mode Remote Servers

Alright so I have a server box with HAProxy installed and I need it to forward traffic to two MySQL servers. They are both located in completely different datacenters. It works when I have this ...
0
votes
0answers
10 views

haproxy acl to check if a file exists (for gracefully taking a site offline)?

I've often used the following snippet in my nginx configs to easily take my sites down for maintenance: location / { if ( -f $document_root/offline ) { return 503; } ... } Then ...
0
votes
0answers
33 views

HAProxy HTTP 503 error on about 50% of requests

I am trying to set up a loadbalancing with HAProxy (on Ubuntu 16.04) and have a strange behaviour with HTTPS-requests: About 50% of the requests return a HTTP 503 Service Unavailable error. Starting ...
-1
votes
1answer
22 views

how to configure HAProxy as a reverse proxy?

I have multiple web servers, hosting multiple domains. Occasionally, I need to move a domain from one web server to another. Rather than have to update the DNS for the domain to point at the new ...
0
votes
1answer
20 views

HAProxy: the ACL can't detect the client hostname

I configured an HAProxy server that should detect if the request comes from server.company.cxx and forward the request to the server on 10.0.x.x. If the request does not fulfill this condition, it ...
0
votes
0answers
12 views

Backend server selection based on cookies priorities.

I am using haproxy 1.6.5 on debian 8.3. I have 4 backend servers. They all do the same thing but diveded to 2 clusters. It is desired to keep session within 1 cluster even if one of the servers in ...
1
vote
1answer
25 views

reconfiguring haproxy backend dynamically

My requirement is to have ~50 haproxy http backends, which will be added and removed dynamically (without my involvement) anywhere on the internal network. I can assume that each http backend knows ...
2
votes
1answer
24 views

Add a mysql check to haproxy

I'm attempting to add a mysql check for haproxy in which if the service wasn't available it would return an error page just as the below config does with the http servers. I'm just not sure of the ...
1
vote
1answer
62 views

Autoscaling containers through consul and registrator

I am using an infrastructure platform consisting of docker containers running on a CentOS host. Scaling multiple containers through docker compose. Consul for service discovery. Registrator for ...
1
vote
1answer
22 views

Add a server to haproxy with initial state

Whenever I update my haproxy configuration to add a node, haproxy adds it in the UP state by default. With the next health check, it is marked as down. Is there a way to add a node in the DOWN or ...
1
vote
1answer
24 views

Haproxy http-buffer-request not working

I can't get Haproxys http-buffer-request option working. I'm using Haproxy 1.6.5. This is my configuration: global maxconn 20000 debug defaults HTTP mode http option http-buffer-request # ...
1
vote
1answer
52 views

HA Proxy ACL on domain name and context name

I have request coming from different URLs like https://example1.com/context1 https://example1.com/context2 https://example2.com/context1 https://example2.com/context2 There might be multiple ...
0
votes
1answer
29 views

HaProxy Listen for both MySQL and HTTP

I realise that using HAPROXY for databases and servers works better if the database servers are external and separate but is it possible to have 2 servers replicating database and files to each other ...
0
votes
1answer
74 views

How can I configure an HAProxy server running behind a firewall?

I am having trouble with the following: I am setting up an HAProxy load balancer on CentOS 7 behind a firewall. The firewall on the HAProxy server as well as the outside firewall are configured so ...
0
votes
1answer
25 views

Integrating Web Application Firewall into this architecture

I need some help figuring out how to implement a Web Application Firewall (WAF) in my existing architecture. Currently I have 2 HAproxy servers clustered using keepalived which are responsible for ...
0
votes
0answers
49 views

HAproxy domain name to backend mapping for path(url) based routing

Does HAProxy support domain name to backend mapping for path based routing. Currently it does support maps for vhost: frontend xyz <other_lines> use_backend backend1 if { hdr(Host) -i ...
1
vote
1answer
52 views

haproxy 1.5 specific source IP address show <NOSRV> 503 SC in haproxy log

I have an unusual problem (as everyone does on this site). I have HAProxy listening on port 80 and 443. I am offloading SSL encryption to HAproxy and passing all traffic to my web servers on port 80. ...
0
votes
0answers
8 views

Haproxy log in with more precision

Using Haproxy, is there a way to log Tq/Tw/Tc/Tr/Tt values (HTTP mode) with more precision? (or in different units than milliseconds, e.g. in microseconds)
2
votes
0answers
43 views

How to set up authentication server before request reach API server using HAProxy?

I want a set up that would force all requests to be authenticated before reaching the application server. I'm seeing HAProxy support basic HTTP Authentication but I couldn't find any info about making ...
0
votes
0answers
57 views

Squid proxy behind Haproxy

In my configuration, I use Haproxy mainly for reverse proxy. I installed Squid Proxy in my private lan and I can access it from external with port 3128. But I use the basic authentification ncsa and ...
1
vote
1answer
24 views

Why is haproxy ignoring the ssl keyword on a backend?

I'm trying to setup backend servers with ssl between the LB and the Server (172.16.12.34 is hosting http and https on the standard ports) backend test balance source option httpchk ...
0
votes
0answers
31 views

HAProxy - How to raise the log level of responses with status code above 400

Here's my sample configuration: frontend www-http bind *:80 acl status_error status ge 400 http-response set-log-level err if status_error default_backend www-backend backend www-...
1
vote
0answers
36 views

Capture and forward extended PKI cert attributes (e.g. UPN) using haproxy

I'm trying to pull an attribute from a client certificate in a mutual authentication scenario and set it as a HTTP header in the request to backend. See fig 1 below. fig1 [user with correct ...
0
votes
0answers
39 views

HAproxy ssl re-encryption and http header modification

I want to use my Haproxy 1.6.5 as Https load balancer before my https servers but I stuck with a problem of misunderstanding . I want this behaviour: haproxy is available as https://example.com but ...
1
vote
0answers
62 views

haproxy with SSL in front of apache for local development

I work on a web app that regularly makes AJAX calls to a REST server that (in production) is accessed via the same domain. While developing locally, I have been redirecting REST calls to a dev server ...
0
votes
2answers
45 views

Load Balancing & High Availability Network Limitations

I'm in the process of coming up with a highly available Apache / MySql group of virtual servers using HAProxy Reverse Proxy & Keepalive. I'm aware that I'm going to be using a floating public ip, ...
0
votes
1answer
80 views

Simple redirect to HAproxy backend servers

I want to configure simple redirect with HAproxy. Desired behaviour: HAProxy receives request to example.com or https://example.com and returns https webserver start page from servers list excluding ...
2
votes
0answers
30 views

HAProxy, why would a replaced HTTP header have a number at the end?

Can someone explain what the "X-Forwarded-Proto2" header is in this HAProxy frontend stanza?: frontend main *:443 ... reqirep ^(X-Forwarded-Proto:)(.*) X-Forwarded-Proto2:\2 ... I understand ...
0
votes
0answers
20 views

Haproxy with mixed modes: SSL offloading and passthrough

I would like to implement the following simple scenario, all the tests I have done unfortunately have failed (bad SSL requests, error 502...): Using SSL passthrough for the top level domain (...
0
votes
2answers
40 views

Simple tool to monitor HAProxy web requests?

I'm looking for a tool that can monitor the number of requests that are going to the nodes within HAProxy to determine the need to push out another node to loadbalance the requests. Can something like ...
0
votes
0answers
22 views

Monitoring HAProxy to determine need to scale

I'm learning about load-balancing and auto scaling at the moment. I have a VM running HAproxy with 3 nodes under it to distribute traffic. My endgoal is to spam it to overload number of requests it ...