Received: from localhost (unknown [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id EA6E49FC509 for ; Fri, 19 Oct 2007 15:21:36 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 89980-02 for ; Fri, 19 Oct 2007 15:21:26 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.173]) by postgresql.org (Postfix) with ESMTP id 3B3B49FC50E for ; Fri, 19 Oct 2007 15:21:27 -0300 (ADT) Received: by ug-out-1314.google.com with SMTP id j3so645225ugf for ; Fri, 19 Oct 2007 11:21:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=pfWLm/jCYgr32u27b7Eh1Eayfu3etWL/iPdTHAyT6GE=; b=eL9z01778bCaNzQjNYxD/UpBFTuonVkIJ1dbcwzbjmsNLrUo39PKDvS7SJ65ajEnkViNEmu0bF6T/3rD/8RmaXHHzrrH61v8AB+df83hvTEefWScA1AP/tkczXjWb0U8Rudbkooxy+8jCC3gkeV4jSFU3zBuBBDPa9gnqKX/wfA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Kt1zRndYs7n4eAr839vzIh5GEs0ClLK7KANmhIjyqZ8AofDMK+3rQpdRg/ZIH374/b3wFJbqQE8CQr9YVaIdyRaCeWWxQnESPp/0KkSQZ14Y774mQO3AyQnp3J81t6+mmzlInnPyqHqp4SYigzTcBShe5eds97rH2O1AQr4d4IQ= Received: by 10.66.252.8 with SMTP id z8mr3320169ugh.1192818086530; Fri, 19 Oct 2007 11:21:26 -0700 (PDT) Received: by 10.67.29.6 with HTTP; Fri, 19 Oct 2007 11:21:26 -0700 (PDT) Message-ID: Date: Fri, 19 Oct 2007 13:21:26 -0500 From: "Scott Marlowe" To: "Yinan Li" Subject: Re: how to improve the performance of creating index Cc: pgsql-performance@postgresql.org In-Reply-To: <01c601c81247$3b8c5650$b2a502f0$@ust.hk> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <01c601c81247$3b8c5650$b2a502f0$@ust.hk> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200710/234 X-Sequence-Number: 27256 On 10/19/07, Yinan Li wrote: > > Hi, all > I am trying to improve the performance of creating index. > I've set shared_buffers = 1024MB > Effective_cache_size = 1024MB > Work_mem = 1GB > Maintenance_work_mem=512MB > (I'm sure that the server process has received the SIGHUP signal) > > However, when create index, I found that the memory used by Postgres is only > 50MB. And it is very slow. How to make it faster? What, exactly is the create index statement? I assume that if there's only two columns then at worst it's a two part index (i.e. column1, column2) which can get rather large.