X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 4FB423A55C9; Wed, 1 Dec 2004 14:25:12 +0000 (GMT) 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 29119-07; Wed, 1 Dec 2004 14:25:02 +0000 (GMT) Received: from velocity.dnsracks.com (unknown [69.93.167.170]) by svr1.postgresql.org (Postfix) with ESMTP id C739F3A55F1; Wed, 1 Dec 2004 14:25:02 +0000 (GMT) Received: from proxy.pspl.co.in ([203.199.147.2] helo=ps0499.persistent.co.in) by velocity.dnsracks.com with esmtpsa (TLSv1:RC4-MD5:128) (Exim 4.43) id 1CZVPa-0006jA-Gu; Wed, 01 Dec 2004 19:54:55 +0530 From: Shridhar Daithankar To: grupos@carvalhaes.net Subject: Re: [PERFORM] pg_restore taking 4 hours! Date: Wed, 1 Dec 2004 19:55:23 +0530 User-Agent: KMail/1.7 Cc: pgsql-general@postgresql.org, pgsql-performance@postgresql.org References: <41ADA82A.7070405@carvalhaes.net> In-Reply-To: <41ADA82A.7070405@carvalhaes.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200412011955.23543.ghodechhap@ghodechhap.net> X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - velocity.dnsracks.com X-AntiAbuse: Original Domain - postgresql.org X-AntiAbuse: Originator/Caller UID/GID - [0 0] / [47 12] X-AntiAbuse: Sender Address Domain - ghodechhap.net X-Source: X-Source-Args: X-Source-Dir: X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.05 tagged_above=0 required=5 tests=FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200412/49 X-Sequence-Number: 69661 On Wednesday 01 Dec 2004 4:46 pm, Rodrigo Carvalhaes wrote: > I need to find a solution for this because I am convincing customers > that are using SQL Server, DB2 and Oracle to change to PostgreSQL but > this customers have databases of 5GB!!! I am thinking that even with a > better server, the restore will take 2 days! > > My data: > Conectiva Linux 10 , Kernel 2.6.8 > PostgreSQL 7.4.6. > > postgresql.conf modified parameters (the other parameters are the default) > tcpip_socket = true > max_connections = 30 > shared_buffers = 30000 > sort_mem = 4096 > vacuum_mem = 8192 > max_fsm_pages = 20000 > max_fsm_relations = 1000 Can you try bumping sort mem lot higher(basically whatever the machine can afford) so that index creation is faster? Just try setting sort mem for the restore session and see if it helps.. Shridhar