HTTP Keep-alive

2009-12-02 Thread Mark Brooks
We were running into communication problems with the web page stalling as it loaded then waited until haproxy hit its timeout. We worked it out to be the HTTP keep-alive, which we have now disabled with option httpclose. I have 2 questions - 1. should haproxy allow the http keep-alive connection

Re: redirecting many urls

2009-12-02 Thread Matt
I guess this can't be done at the moment? Is there a feature request for this already? Thanks, Matt 2009/12/1 Matt mattmora...@gmail.com: Hi all, I'm trying to do the following apache rewrite rule in haproxy - RewriteRule ^/([a-z]+)/mypage$  http://mydomain.com/$1/yourpage [R=301,L,NE]

Re: [BUG] Configuration parser bug when escaping characters

2009-12-02 Thread Willy Tarreau
Hi Cyril, On Mon, Nov 30, 2009 at 07:19:00PM +0100, Cyril Bonté wrote: Hello Willy, Today I was testing headers manipulation but I met a bug with my first test. To reproduce it, add for example this line : rspadd Cache-Control:\ max-age=1500 Check the response header, it will

Re: need some help please

2009-12-02 Thread Willy Tarreau
On Wed, Dec 02, 2009 at 07:51:58AM +0200, Paul Roland wrote: nvm this, sorry. I was using tcp mode... OK. With 1.4-dev you'd be able to do that in TCP mode, though you'd have to add a statement to wait for an HTTP request. But I have another question, can I limit connections per ip with

Re: redirecting many urls

2009-12-02 Thread Willy Tarreau
Hi Matt, On Wed, Dec 02, 2009 at 12:58:50PM +, Matt wrote: I guess this can't be done at the moment? Is there a feature request for this already? (...) RewriteRule ^/([a-z]+)/mypage$  http://mydomain.com/$1/yourpage [R=301,L,NE] Sorry, but I'm unable to parse apache's cryptic

Re: HTTP Keep-alive

2009-12-02 Thread Willy Tarreau
On Wed, Dec 02, 2009 at 11:23:14AM +, Mark Brooks wrote: We were running into communication problems with the web page stalling as it loaded then waited until haproxy hit its timeout. We worked it out to be the HTTP keep-alive, which we have now disabled with option httpclose. Most often

Re: weird tcp syn/ack problem

2009-12-02 Thread Willy Tarreau
Hi, On Wed, Dec 02, 2009 at 04:47:01PM -0500, Lincoln wrote: Hi, I'm running HAProxy as my load balancer and sometimes (but not all the time) clients experience an 11s delay. The delay is always about 11s when it happens. I used Wireshark to try and see what was happening (screenshot from

Re: [BUG] Configuration parser bug when escaping characters

2009-12-02 Thread Cyril Bonté
Le mercredi 2 décembre 2009 23:12:50, Willy Tarreau a écrit : I find it particularly amazing that you're the first to observe this, considering how old those parts are ! That also surprised me, then I've made some more tests : this only happens when we use backslashes on the last line of the

Re: [BUG] Configuration parser bug when escaping characters

2009-12-02 Thread Willy Tarreau
On Wed, Dec 02, 2009 at 11:47:03PM +0100, Cyril Bonté wrote: Le mercredi 2 décembre 2009 23:12:50, Willy Tarreau a écrit : I find it particularly amazing that you're the first to observe this, considering how old those parts are ! That also surprised me, then I've made some more tests :

Re: weird tcp syn/ack problem

2009-12-02 Thread Lincoln
Thanks Willy for offering to help us out with this. We are running on an Amazon EC2 m1small instance which is very common for a load balancer machine. I changed /proc/sys/net/ipv4/tcp_timestamps to 1 - unfortunately to no effect. Here are my iptables settings (nothing special here that I can

Load balancing PostFix Mail Out

2009-12-02 Thread boris17...@gmail.com
I'm currently trying to load balance balance Mailout from postfix MTA. It work nice, but I have some question (maybe feature). I want to add a custom header (this one is just after a test) but rspadd seem to work only on http. rspadd X-HAProxyRocks:\ Yes\0 Our mail sender is a

RE: Load balancing PostFix Mail Out

2009-12-02 Thread John Lauro
I think haproxy can only do header manipulation with HTTP. In other words, rspadd will not work with mode tcp. You should be able to have your PHP scrip add the custom header. Postfix can handle a lot of outgoing mail. If you don't mind me asking, I'm just curious how much mail are you

Re: Load balancing PostFix Mail Out

2009-12-02 Thread boris17...@gmail.com
We are handle arround 500'000 mails 3 times by week, but we have to load balance because we used dkimproxy for signing emails, and we have to use 3 IPs to don't be bad for mail services receiver. Yes I read that for the header manipulation (that's why I said maybe request). It's not *only*

Re: weird tcp syn/ack problem

2009-12-02 Thread Willy Tarreau
On Wed, Dec 02, 2009 at 07:44:40PM -0500, Lincoln wrote: Thanks Willy for offering to help us out with this. We are running on an Amazon EC2 m1small instance which is very common for a load balancer machine. I changed /proc/sys/net/ipv4/tcp_timestamps to 1 - unfortunately to no effect.

Re: weird tcp syn/ack problem

2009-12-02 Thread Lincoln
Hi Willy, I agree it's pretty confusing. I should have been clearer - the problem does not happen every time, it's very random. But when it happens it always follows that exact pattern - that's what I meant to say. I actually have somaxconn set to 1 so I don't think that's the issue. At

Re: Load balancing PostFix Mail Out

2009-12-02 Thread Willy Tarreau
On Thu, Dec 03, 2009 at 06:09:06AM +0100, boris17...@gmail.com wrote: We are handle arround 500'000 mails 3 times by week, but we have to load balance because we used dkimproxy for signing emails, and we have to use 3 IPs to don't be bad for mail services receiver. But your first postfix or

Re: weird tcp syn/ack problem

2009-12-02 Thread Willy Tarreau
On Thu, Dec 03, 2009 at 12:29:55AM -0500, Lincoln wrote: Hi Willy, I agree it's pretty confusing. I should have been clearer - the problem does not happen every time, it's very random. But when it happens it always follows that exact pattern - that's what I meant to say. OK, that's what I

Re: Load balancing PostFix Mail Out

2009-12-02 Thread Willy Tarreau
On Thu, Dec 03, 2009 at 06:55:19AM +0100, boris17...@gmail.com wrote: Le 03/12/2009 06:40, Willy Tarreau a écrit : On Thu, Dec 03, 2009 at 06:09:06AM +0100, boris17...@gmail.com wrote: We are handle arround 500'000 mails 3 times by week, but we have to load balance because we used