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 4ECB85E46C6 for ; Fri, 6 Aug 2004 13:11:14 -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 14629-09 for ; Fri, 6 Aug 2004 16:11:16 +0000 (GMT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id A43255E46D0 for ; Fri, 6 Aug 2004 13:11:08 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.12.9/8.12.9) with ESMTP id i76GB65r081375 for ; Fri, 6 Aug 2004 16:11:16 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.12.9/8.12.9/Submit) id i76G1bLA080127 for pgsql-performance@postgresql.org; Fri, 6 Aug 2004 16:01:37 GMT From: Gaetano Mendola X-Newsgroups: comp.databases.postgresql.performance Subject: Re: [GENERAL] Tuning queries on large database Date: Thu, 05 Aug 2004 11:53:59 +0200 Organization: PYRENET Midi-pyrenees Provider Lines: 36 Message-ID: <411203B7.8050706@bigfoot.com> References: <200408050816.i758GxO21560@mu.meteo.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@pyrenet.fr To: Valerie Schneider DSI/DEV User-Agent: Mozilla Thunderbird 0.7.1 (Windows/20040626) X-Accept-Language: en-us, en In-Reply-To: <200408050816.i758GxO21560@mu.meteo.fr> X-Enigmail-Version: 0.84.2.0 X-Enigmail-Supports: pgp-inline, pgp-mime To: pgsql-performance@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200408/75 X-Sequence-Number: 7711 Valerie Schneider DSI/DEV wrote: > Hi, > I 've decreased the sort_mem to 5000 instead of 50000. > I recreated ma table using integer and real types instead of > numeric : the result is very improved for the disk space : > > schema | relfilenode | table | index | reltuples | size > --------+-------------+------------------+------------+-------------+---------- > public | 253442696 | data | | 1.25113e+08 | 29760016 > public | 378639579 | data | i_data_dat | 1.25113e+08 | 2744400 > public | 378555698 | data | pk_data | 1.25113e+08 | 3295584 > > so it takes about 28 Gb instead of 68 Gb ! > > For my different queries, it's better but less performant than oracle : > > oracle PG yesterday(numeric) PG today(integer/real) > Q1 <1s <1s <1s > Q2 3s 8s 4s > Q3 8s 1m20s 27s > Q4 28s 17m20s 6m47s Are you using the same disk for oracle and PG ? Could you post your actual postgresql.conf ? Try also to mount your partition with the option: noatime and try again. Regards Gaetano Mendola