X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id C048A529F6 for ; Tue, 9 Aug 2005 15:58:43 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 99823-07 for ; Tue, 9 Aug 2005 18:58:40 +0000 (GMT) Received: from mail.tecarta.com (66.238.115.135.ptr.us.xo.net [66.238.115.135]) by svr1.postgresql.org (Postfix) with ESMTP id 59927529F4 for ; Tue, 9 Aug 2005 15:58:39 -0300 (ADT) Received: from mail pickup service by mail.tecarta.com with Microsoft SMTPSVC; Tue, 9 Aug 2005 12:02:24 -0700 Received: from mail.tecarta.com ([192.168.160.2]) by mail.tecarta.com with Microsoft SMTPSVC(6.0.3790.0); Tue, 9 Aug 2005 12:02:21 -0700 Received: from barracuda.tecarta.com ([192.168.160.200]) by mail.tecarta.com (SAVSMTP 3.1.0.29) with SMTP id M2005080912022128114 for ; Tue, 09 Aug 2005 12:02:21 -0700 X-ASG-Debug-ID: 1123613917-1115-6-0 X-Barracuda-URL: http://192.168.160.200:8000/cgi-bin/mark.cgi Received: from mail1 (mail1.hq.corp [192.168.160.5]) by barracuda.tecarta.com (Spam Firewall) with SMTP id 622B62014AF5 for ; Tue, 9 Aug 2005 11:58:37 -0700 (PDT) Received: from amd64-laptop-spoe ([63.206.203.145]) by mail.tecarta.com with Microsoft SMTPSVC(6.0.3790.1830); Tue, 9 Aug 2005 12:02:20 -0700 X-ASG-Orig-Subj: Re: [PERFORM] Table locking problems? Subject: Re: Table locking problems? From: Steve Poe To: Dan Harris Cc: pgsql-performance@postgresql.org In-Reply-To: <52CFA236-FC43-4018-B399-1854240110FF@drivefaster.net> References: <52CFA236-FC43-4018-B399-1854240110FF@drivefaster.net> Content-Type: text/plain Date: Wed, 10 Aug 2005 06:49:07 +0000 Message-Id: <1123656547.13362.43.camel@amd64-laptop-spoe> Mime-Version: 1.0 X-Mailer: Evolution 2.2.3 Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 09 Aug 2005 19:02:20.0428 (UTC) FILETIME=[DE4AD4C0:01C59D14] X-Virus-Scanned: by Barracuda Spam Firewall at tecarta.com X-Barracuda-Spam-Score: 1.30 X-Barracuda-Spam-Status: No, SCORE=1.30 using global scores of TAG_LEVEL=4.0 QUARANTINE_LEVEL=1000.0 KILL_LEVEL=7.0 tests=BAYES_50, DATE_IN_FUTURE_06_12 X-Barracuda-Spam-Report: Code version 3.02, rules version 3.0.3093 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- 1.30 DATE_IN_FUTURE_06_12 Date: is 6 to 12 hours after Received: date 0.00 BAYES_50 BODY: Bayesian spam probability is 40 to 60% [score: 0.5985] X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.75 tagged_above=0 required=5 tests=AWL, DATE_IN_FUTURE_06_12, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200508/89 X-Sequence-Number: 13836 Dan, Do you mean you did RAID 1 + 0 (RAID 10) or RAID 0 + 1? Just a clarification, since RAID 0 is still a single-point of failure even if RAID1 is on top of RAID0. How many users are connected when your update / delete queries are hanging? Have you done an analyze verbose on those queries? Have you made changes to the postgresql.conf? kernel.vm settings? IO scheduler? If you're not doing so already, you may consider running sar (iostat) to monitor when the hanging occurs if their is a memory / IO bottleneck somewhere. Good luck. Steve Poe On Tue, 2005-08-09 at 12:04 -0600, Dan Harris wrote: > I thought I would send this to pg-performance since so many people > helped me with my speed issues recently. I was definitely IO- > bottlenecked. > > Since then, I have installed 2 RAID arrays with 7 15k drives in them > in RAID 0+1 as well as add a new controller card with 512MB of cache > on it. I also created this new partition on the RAID as XFS instead > of ext3. > > These changes have definitely improved performance, but I am now > finding some trouble with UPDATE or DELETE queries "hanging" and > never releasing their locks. As this happens, other statements queue > up behind it. It seems to occur at times of very high loads on the > box. Is my only option to kill the query ( which usually takes down > the whole postmaster with it! ouch ). > > Could these locking issues be related to the other changes I made? > I'm really scared that this is related to choosing XFS, but I sure > hope not. How should I go about troubleshooting the "problem" > queries? They don't seem to be specific to a single table or single > database. > > I'm running 8.0.1 on kernel 2.6.12-3 on 64-bit Opterons if that > matters.. > > > -Dan > > ---------------------------(end of broadcast)--------------------------- > TIP 9: In versions below 8.0, the planner will ignore your desire to > choose an index scan if your joining column's datatypes do not > match