Re: Connections getting stuck sending data to client (FIXED)

From: Chris Butler <chrisb(at)zedcore(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Connections getting stuck sending data to client (FIXED)
Date: 2008-11-03 13:37:06
Message-ID: 20081103133705.GG21046@zedcore.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

[Forgot to send this to the list first time]

On Fri, Oct 31, 2008 at 12:27:27PM -0600, Scott Marlowe wrote:
> On Fri, Oct 31, 2008 at 9:36 AM, Chris Butler <chrisb(at)zedcore(dot)com> wrote:
> > I've been having intermittent problems with our DB server (running
> > postgresql 8.3.3) reaching its connection limit, all because of a SELECT
> > statement that's stuck while sending data. This gets stuck because there's a
> > transaction waiting to do an ALTER TABLE, then the subsequent SELECTs wait
> > for the ALTER.
> >
> > The problem seems to be that the client connection drops while the server is
> > sending data to the client.
> Are the clients windows? I know there's a well known and published
> bug in windows where it freaks out on blocking ports and the
> connection hangs. There's a kb article on it on the ms site. It's
> been around since windows 95 or so and there appears to be no plans to
> fix it.

The client is a PHP webapp running on a Debian VPS.

Shortly after sending my previous message, I did spot an error in the
client's firewall. It was sending back an ICMP port-unreachable when
rejecting TCP packets, rather than a TCP Reset, which I guess is why the
connection stayed open rather than closing immediately.

Still unsure why it's dropping the connection, but at least it doesn't get
stuck any more.

--
Chris Butler
Zedcore Systems Ltd
UK tel: 0114 238 1828 ext 72

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Ivan Sergio Borgonovo 2008-11-03 14:14:14 raise notice, psql and having some feedback from scripts
Previous Message Harald Fuchs 2008-11-03 12:41:52 Re: Redefining an existing Table Schema for Foreign Key Constraint - Question