Re: how can we resolving locking state....

From: Andreas 'ads' Scherbaum <adsmail(at)wars-nicht(dot)de>
To: pgsql-general(at)postgresql(dot)org
Cc: 노현석 <noh019(at)naver(dot)com>
Subject: Re: how can we resolving locking state....
Date: 2010-08-05 18:03:46
Message-ID: 20100805200346.7d065ae6@platin.wars-nicht.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


Hi,

On Thu, 05 Aug 2010 17:52:44 +0900 노현석 wrote:

> we test locking PostgreSQL 8.4.4 on x86_64.
>

[...]

> begin;
> delete from citytest;
> &lt;------- no commit/rollback
> &lt;------- this will be Blocker
>
> 2> session 2,3,4
> ###########################
> $ psql mydb
> delete from citytest;
> &lt;--- waiting
> &lt;--- these are blocked....

[...]

> Could you teach me, Is this expected behavior ?? (disapper blocking
> process not only Blocker process) and
> Could you teach me, how can we eliminate just Blocker session...

Note: the cause for the blocked sessions is in your first session. By
deleting all entries from table "citytest", PG will lock all deleted
entries. Once you try to delete one or all of this rows in another
session, PG waits until the first session is either committed or rolled
back.

This is expected behaviour.

Bye

--
Andreas 'ads' Scherbaum
Failure is not an option. It comes bundled with your Microsoft product.
(Ferenc Mantfeld)

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Scott Marlowe 2010-08-05 19:08:29 Re: how can we resolving locking state ....
Previous Message pgsql-general 2010-08-05 16:54:19 pgsql-general@news.hub.org 37% OFF on Pfizer!