Re: Core dump when trying to reload haproxy

From: Anders Nordby <anders#FreeBSD.org>
Date: Tue, 11 Nov 2008 11:57:55 +0100


Hi,

On Tue, Nov 11, 2008 at 09:45:01AM +0100, Willy Tarreau wrote:

>> /usr/local/sbin/haproxy -p /var/run/haproxy.pid -f /usr/local/etc/haprox
>> y.conf -sf `cat /var/run/haproxy.pid`
>> Haproxy core-dumps on signal 6 (SIGABRT):
>> (..)

> No idea right now, this is pretty unexpected. What version is this ?
> From the line number, it looks like it is version 1.2.

This is version 1.2.18.

> If so, it seems that if an error happens while shutting down a listener's FD,
> the proxy enters the PR_STERROR state, which does not prevent the FD from
> being closed. I think that we should explicitly set the fd to -1 in case
> of error in pause_proxy() and avoid the call to fd_delete() in
> maintain_proxies() if the fd is -1.

Ok.

> If you can confirm your version, I can work on a patch which I will ask
> you to try.

Cool, I'll check it out when you have something.

>> This is in FreeBSD.

> I'm not surprised, because when doing a shutdown() on a listen socket,
> we have 3 different behaviours: linux, bsd and solaris. Hence, having
> one of those trigger a bug not seen on others has nothing surprising.

It seems the problem does not exist after upgrading from FreeBSD 6.2 to 7.0. I just recently did that, and now haproxy does not core-dump when reloading. Hmm. It could be you still want to fix something related to my problem however? I assume you want it to work on several platforms, given your reply. :)

Cheers,

-- 
Anders.
Received on 2008/11/11 11:57

This archive was generated by hypermail 2.2.0 : 2008/11/11 12:01 CET