Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id D8B6B6329F1 for ; Fri, 31 Jul 2009 20:49:19 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 29948-04 for ; Fri, 31 Jul 2009 23:49:02 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from lists.commandprompt.com (host-159.commandprompt.net [207.173.203.159]) by mail.postgresql.org (Postfix) with ESMTP id 2A35C632F55 for ; Fri, 31 Jul 2009 20:49:08 -0300 (ADT) Received: from perhan.alvh.no-ip.org (201-220-118-158.bk10-dsl.surnet.cl [201.220.118.158]) (authenticated bits=0) by lists.commandprompt.com (8.13.8/8.13.8) with ESMTP id n6VNvvO2003742 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 31 Jul 2009 16:57:59 -0700 Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id 1D739D419D; Fri, 31 Jul 2009 19:49:02 -0400 (CLT) Date: Fri, 31 Jul 2009 19:49:02 -0400 From: Alvaro Herrera To: Luke Koops Cc: pgsql-bugs@postgresql.org Subject: Re: BUG #4958: Stats collector hung on WaitForMultipleObjectsEx while attempting to recv a datagram Message-ID: <20090731234901.GD11098@alvh.no-ip.org> References: <200907311459.n6VExuSa036743@wwwmaster.postgresql.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200907311459.n6VExuSa036743@wwwmaster.postgresql.org> User-Agent: Mutt/1.5.20 (2009-06-14) X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.0 (lists.commandprompt.com [207.173.203.159]); Fri, 31 Jul 2009 16:58:00 -0700 (PDT) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.004 tagged_above=-10 required=5 tests=AWL=0.004 X-Spam-Level: X-Archive-Number: 200907/365 X-Sequence-Number: 23827 Luke Koops wrote: > Description: Stats collector hung on WaitForMultipleObjectsEx while > attempting to recv a datagram > Details: > > While running a load test with 80 processes connected to postgres, of which > 62 were generating load, the stats collector got blocked on > WaitForMultipleObjectsEx which was called with INFINITE timeout. The stack > trace for the hung thread follows: > ntdll.dll!NtWaitForMultipleObjects+0xc > kernel32.dll!WaitForMultipleObjectsEx+0x11a > postgres.exe!pgwin32_waitforsinglesocket+0x1ed > postgres.exe!pgwin32_recv+0x90 > postgres.exe!PgstatCollectorMain+0x17f > postgres.exe!SubPostmasterMain+0x33a > postgres.exe!main+0x168 > postgres.exe!__tmainCRTStartup+0x10f > kernel32.dll!BaseProcessStart+0x23 I have seen this problem too. The process seems stuck for no good reason. I wondered at the time if it could be a kernel issue. I remember trying to send some data to the collector to verify whether it'd wake up, but no luck. (I mean I couldn't find a way to do it on Windows). -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support