From: Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
To: Kevin Grittner <Kevin.Grittner@wicourts.gov>
Cc: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
Cc: drkp@csail.mit.edu
Cc: pgsql-hackers@postgresql.org
Subject: Re: SSI bug?
Date: Thu, 31 Mar 2011 18:50:19 +0300
Message-ID: <4D94A2BB.3090605@enterprisedb.com> (raw)
In-Reply-To: <4D943BEC020000250003BFDA@gw.wicourts.gov>
References: <4D8F54E6020000250003BD16@gw.wicourts.gov>
<4D8F54E6020000250003BD16@gw.wicourts.gov>
<20110328031616.CDAA719CEDF@mail.netbsd.org>
<4D943BEC020000250003BFDA@gw.wicourts.gov>
On 31.03.2011 16:31, Kevin Grittner wrote:
> I've stared at the code for hours and have only come up with one
> race condition which can cause this, although the window is so small
> it's hard to believe that you would get this volume of orphaned
> locks. I'll keep looking, but if you could try this to see if it
> has a material impact, that would be great.
>
> I am very sure this patch is needed and that it is safe. It moves a
> LWLockAcquire statement up to cover the setup for the loop that it
> already covers. It also includes a fix to a comment that got missed
> when we switched from the pointer between lock targets to
> duplicating the locks.
Ok, committed.
Did we get anywhere with the sizing of the various shared memory
structures? Did we find the cause of the "out of shared memory" warnings?
Would it help if we just pre-allocated all the shared memory hash tables
and didn't allow them to grow? It's bizarre that the hash table that
requests the slack shared memory space first gets it, and it can't be
reused for anything else without a server restart. I feel it would make
better to not allow the tables to grow, so that you get consistent
behavior across restarts.
--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: heikki.linnakangas@enterprisedb.com, Kevin.Grittner@wicourts.gov, yamt@mwd.biglobe.ne.jp, drkp@csail.mit.edu
Subject: Re: SSI bug?
In-Reply-To: <4D94A2BB.3090605@enterprisedb.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox