X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 67C205E46F5 for ; Sun, 22 Aug 2004 23:59:23 -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 59568-02 for ; Mon, 23 Aug 2004 02:59:25 +0000 (GMT) Received: from grunt11.ihug.co.nz (grunt11.ihug.co.nz [203.109.254.54]) by svr1.postgresql.org (Postfix) with ESMTP id 2FE195E46F3 for ; Sun, 22 Aug 2004 23:59:16 -0300 (ADT) Received: from 203-118-172-96.adsl.ihug.co.nz (noggon.com) [203.118.172.96] by grunt11.ihug.co.nz with asmtp (Exim 3.35 #1 (Debian)) id 1Bz53J-0001aG-00; Mon, 23 Aug 2004 14:59:21 +1200 Message-ID: <41295D87.6080806@noggon.com> Date: Mon, 23 Aug 2004 14:59:19 +1200 From: Worik Reply-To: worik@noggon.com User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040530 Debian/1.6-6.backports.org.1 X-Accept-Language: en MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: pg_dump/pg_restore question Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit 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/235 X-Sequence-Number: 18732 Freinds I am new to this list, and this is my first message. I hope this is the correct forum, and the question not too stupid/simple. I have a database on a debian stable system... dpkg -l postgresql [snip] ii postgresql 7.2.1-2woody5 Object-relational SQL database, descended fr When I dump a database (as from the man page for pg_restore) pg_dump mydb > mydb.out OK. Get an SQL dump in mydb.out Create a new database.... creatdb myotherdb Load the dump.... psql -d myotherdb -f mydb.out psql:mydb.out:4: \connect: FATAL 1: IDENT authentication failed for user "postgres" I have tried adding the line host all 127.0.0.1 255.255.255.255 trust to pg_hba.conf but it makes no difference. The only thing I can do is edit the dump file into the part that wants to connect as postgres and the part that wants to connect as worik and run them under their respective logins. How can I set it up so I do not have to do that? What documentation should I be reading? Worik