Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 06D7F633CE6 for ; Thu, 14 Jan 2010 12:15:33 -0400 (AST) 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 45863-09 for ; Thu, 14 Jan 2010 16:15:21 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from 63.mail-out.ovh.net (63.mail-out.ovh.net [91.121.185.56]) by mail.postgresql.org (Postfix) with SMTP id DAF8063341E for ; Thu, 14 Jan 2010 12:15:20 -0400 (AST) Received: (qmail 7233 invoked by uid 503); 14 Jan 2010 16:16:03 -0000 Received: from b6.ovh.net (HELO mail180.ha.ovh.net) (213.186.33.56) by 63.mail-out.ovh.net with SMTP; 14 Jan 2010 16:16:03 -0000 Received: from b0.ovh.net (HELO queueout) (213.186.33.50) by b0.ovh.net with SMTP; 14 Jan 2010 16:15:18 -0000 Received: from par69-8-88-161-102-87.fbx.proxad.net (HELO soyouz) (88.161.102.87) by ns0.ovh.net with SMTP; 14 Jan 2010 16:15:16 -0000 Date: Thu, 14 Jan 2010 17:16:11 +0100 To: "Eduardo Piombino" , "Craig James" Subject: Re: a heavy duty operation on an "unused" table kills my server From: =?utf-8?Q?Pierre_Fr=C3=A9d=C3=A9ric_Caillau?= =?utf-8?Q?d?= Cc: pgsql-performance@postgresql.org Content-Type: text/plain; format=flowed; delsp=yes; charset=utf-8 MIME-Version: 1.0 References: <4B4D5698.8040808@emolecules.com> Content-Transfer-Encoding: 7bit Message-ID: In-Reply-To: User-Agent: Opera Mail/9.62 (Linux) X-Ovh-Tracer-Id: 4833488301470451362 X-Ovh-Remote: 88.161.102.87 (par69-8-88-161-102-87.fbx.proxad.net) X-Ovh-Local: 213.186.33.20 (ns0.ovh.net) X-Spam-Check: DONE|U 0.5/N X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.571 tagged_above=-10 required=5 tests=AWL=-0.831, BAYES_20=-0.74 X-Spam-Level: X-Archive-Number: 201001/286 X-Sequence-Number: 37166 > "high CPU usage" It might very well be "high IO usage". Try this : Copy (using explorer, the shell, whatever) a huge file. This will create load similar to ALTER TABLE. Measure throughput, how much is it ? If your server blows up just like it did on ALTER TABLE, you got a IO system problem. If everything is smooth, you can look into other things. How's your fragmentation ? Did the disk ever get full ? What does the task manager say (swap in/out, disk queue lengthn etc) PS : try a separate tablespace on another disk.