Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id C3573133740B for ; Mon, 11 Apr 2011 14:55:59 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 51617-10 for ; Mon, 11 Apr 2011 17:55:41 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from gw.wicourts.gov (gwmta.wicourts.gov [165.219.244.99]) by mail.postgresql.org (Postfix) with ESMTP id B4B601337990 for ; Mon, 11 Apr 2011 14:55:40 -0300 (ADT) Received: from Courts-MTA by gw.wicourts.gov with Novell_GroupWise; Mon, 11 Apr 2011 12:55:40 -0500 Message-Id: <4DA2FA41020000250003C672@gw.wicourts.gov> X-Mailer: Novell GroupWise Internet Agent 8.0.1 Date: Mon, 11 Apr 2011 12:55:29 -0500 From: "Kevin Grittner" To: "Gerhard Hintermayer" , "pgsql-admin" Subject: Re: Re: multiple hot standby streaming replication scenario with "rotating" the primary server References: <4DA2E174020000250003C650@gw.wicourts.gov> <4DA2F31C020000250003C665@gw.wicourts.gov> In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=2.409 tagged_above=-10 required=5 tests=BAYES_00=-1.9, FS_REPLICA=3.599, SARE_SPEC_REPLICA=0.72, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: ** X-Archive-Number: 201104/90 X-Sequence-Number: 37271 Gerhard Hintermayer wrote: > I have e.g. a table with: > Indexes: > "idx_auftrag_l1" hash (a_nr) Any *hash* index will need to be rebuilt. Like that one. > Seeing this and reading the docs about the caveats I see no other > solution as to REINDEX all of my DB's :-( As the docs say, you need to REINDEX your *hash* indexes. Most people don't use those because they aren't WAL-logged, which can lead to various problems (including this one) and because there seem to be very few circumstances were they perform better than btree indexes, which don't have such a problem. If you switched to btree indexes where you currently have hash indexes, the REINDEX would be totally unneeded. > I have lot's of tables with primary key a_nr as above (though I > know it is not reflected in the table definition, but should > result in the same result, i.e. a_nr integer PRIMARY KEY would > create an index to lookup the table). I think a PRIMARY KEY constraint normally builds a btree index, which wouldn't have this problem. -Kevin