Re: BUG #10888: application is getting hanged in the poll() function of libpq.so.

From: Mitu Verma <mitu(dot)verma(at)ericsson(dot)com>
To: 'Tom Lane' <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "pgsql-bugs(at)postgresql(dot)org" <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #10888: application is getting hanged in the poll() function of libpq.so.
Date: 2014-07-07 17:18:23
Message-ID: 84BC7AB0D621A74893EC9C9E151293B003F8F581@ESESSMB207.ericsson.se
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi Tom,

Thanks for your response. But at server side it is showing the following behavior .
I am running a single query at this moment.

INSERT INTO eventLogEntry (object, method, bgwUser, time, realUser, host, application, tableIndex ) VALUES (E'Server', E'Start', E'bgw', E'20140512122404', NULL, NULL, NULL, 539 );

So not able to understand whats wrong with the database that it is unable to process this simple insert query.
At the same time if drop the index and recreate the table then this issue is resolved. But obviously this is not a feasible solution in live environment. Plz see if you can provide some help.

>pstack 16950
#0 0x00000000006dc1da in hash_search ()
#1 0x000000000060e430 in LockAcquireExtended ()
#2 0x000000000060c46e in XactLockTableWait ()
#3 0x0000000000476bc6 in _bt_doinsert ()
#4 0x0000000000479882 in btinsert ()
#5 0x00000000006d6d25 in FunctionCall6Coll ()
#6 0x00000000004743c7 in index_insert ()
#7 0x0000000000563375 in ExecInsertIndexTuples ()
#8 0x000000000056eba3 in ExecModifyTable ()
#9 0x000000000055a863 in ExecProcNode ()
#10 0x0000000000559871 in standard_ExecutorRun ()
#11 0x000000000062037f in ProcessQuery ()
#12 0x00000000006205a7 in PortalRunMulti ()
#13 0x0000000000621068 in PortalRun ()
#14 0x000000000061dc5b in exec_simple_query ()
#15 0x000000000061e464 in PostgresMain ()
#16 0x00000000005e38dc in ServerLoop ()
#17 0x00000000005e45dc in PostmasterMain ()
#18 0x0000000000588dbe in main ()

-----Original Message-----
From: Tom Lane [mailto:tgl(at)sss(dot)pgh(dot)pa(dot)us]
Sent: Monday, July 07, 2014 8:24 PM
To: Mitu Verma
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: [BUGS] BUG #10888: application is getting hanged in the poll() function of libpq.so.

mitu(dot)verma(at)ericsson(dot)com writes:
> Application gets hanged while making a query to the PostgreSql database.

> I reproduced the issues on our testbed by making a simple C program
> which makes a synchronous connection with the DB.

> Pstack is showing the following error when the application is hang
> (see
> below)

> Now as it looks that it is getting hanged in the poll() function of
> libpq.so.

That looks like it's just waiting for the server to respond. You sure you didn't simply issue a very long-running query? Check to see if the connected backend process is accumulating CPU time and/or I/O activity.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2014-07-07 17:27:05 Re: BUG #10888: application is getting hanged in the poll() function of libpq.so.
Previous Message Marko Tiikkaja 2014-07-07 16:36:32 Re: BUG #10889: Cannot add 2 floats from regular expression