Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id DC8BD1EB83EB for ; Thu, 23 Feb 2012 14:05:19 -0400 (AST) Received: from smtp.optionshouse.com ([38.98.137.6] helo=smtp.peak6.com) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1S0d2Y-0001eD-UD for pgsql-performance@postgresql.org; Thu, 23 Feb 2012 18:05:19 +0000 X-AuditID: 0a64cb1e-b7b86ae000000b8b-26-4f467f557087 Message-ID: <4F467FCD.8090100@peak6.com> Date: Thu, 23 Feb 2012 12:05:01 -0600 From: Shaun Thomas Reply-To: Organization: Peak6 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:10.0.2) Gecko/20120216 Thunderbird/10.0.2 MIME-Version: 1.0 To: Greg Spiegelberg CC: "Reuven M. Lerner" , Andrew Dunstan , =?UTF-8?B?TWFyY2luIE1hxYRr?= , Subject: Re: Very long deletion time on a 200 GB database References: <4F45FB55.1020600@lerner.co.il> <4F464C49.4050503@dunslane.net> <4F465A7A.4000905@lerner.co.il> In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed content-transfer-encoding: 7bit X-Originating-IP: [10.10.107.46] X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrOIsWRmVeSWpSXmKPExsXCxcQroRta7+Zv0HvI2mLTxwtsFjO7vzJZ 3J91g9Hi+sxzzBbvH+1mcmD16Hl5hdFj56y77B5Tnz1g8biwbxp7AEtUA6NNYl5efkliSapC Smpxsq1SgKujt5mCS2Zxck5iZm5qkZJCZoqtkpmSQkFOYnJqbmpeia1SYkFBal6Kkh2XAgaw ASrLzFNIzUvOT8nMS7dV8gz217WwMLXUNVSyi8cCEppYMi68O8dcsJ+lYsWDpawNjAeYuxg5 OSQETCR+rH7ECmGLSVy4t54NxOYV0JB41ngbLM4ioCqx4OJeMJtNQE1i4e6bjCC2kICsxP5V 58Di/ALCEvs+NAHN5OAQFQiTWPDOE2KMoMTJmU9YQGwRAV2JRUtvApVwcTALbGCUOH32Lliv sICzxKnH59ghZn5llPhyzABkDqdAoMSU6YYgYWYBC4nFbw6yQ9jyEtvfzmGGKJeTuNPwnA3i fAWJOVfbWSYwCs1CsnoWkvZZSNoXMDKvYhQvLktMzsg0LSjOLSkw1CtITcw208tLLdnECIr0 lNNyOxinL1U8xCjAwajEw7ugzs1fiDWxrLgy9xCjBAezkgjvZUegEG9KYmVValF+fFFpTmrx IUZTYJBNZJYSTc4HJqG8knhDY0NLU0tjMwMjE0sLJXFeTh5bfyGBdGBqyE5NLUgtgulj4uCU amBUlp/UL3M8Vls0rDCxMrZpN/vr0/c6An6zz2+8znEl2s3i+cN1e+NYhI+f2/nyW/ik6ElT XqssDDx6ZM8tt/zt/+8ETFcXm2V0Jzjx8L8rm+eJ/Vl1kHfHuv/u3OYhU49uPnw0mfnt888L 74uYTtm10uFkyOt336eqWptNNZEprp8+eU7Ryz93YpRYijMSDbWYi4oTAXNA6yEKAwAA X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201202/173 X-Sequence-Number: 46345 On 02/23/2012 11:56 AM, Greg Spiegelberg wrote: > I know there are perils in using ctid but with the LOCK it should be > safe. This transaction took perhaps 30 minutes and removed 100k rows > and once the table was VACUUM'd afterward it freed up close to 20 GB > on the file system. It took *30 minutes* to delete 100k rows? And 100k rows were using 20GB? Is that off by an order of magnitude? Using the ctid is a cute trick, though. :) -- Shaun Thomas OptionsHouse | 141 W. Jackson Blvd. | Suite 500 | Chicago IL, 60604 312-444-8534 sthomas@peak6.com ______________________________________________ See http://www.peak6.com/email_disclaimer/ for terms and conditions related to this email