Received: from sss.sss.pgh.pa.us (sss.pgh.pa.us [209.114.166.2]) by hub.org (8.9.3/8.9.3) with ESMTP id KAA88876 for ; Mon, 16 Aug 1999 10:25:24 -0400 (EDT) (envelope-from tgl@sss.pgh.pa.us) Received: from sss.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.sss.pgh.pa.us (8.9.1/8.9.1) with ESMTP id KAA00708; Mon, 16 Aug 1999 10:24:16 -0400 (EDT) To: "Dutt H Kalapatapu" cc: "Clint Forgy" , pgsql-interfaces@postgreSQL.org Subject: Re: [INTERFACES] fe_setauthsvc: invalid name. Ignoring... ERROR In-reply-to: Your message of Sun, 15 Aug 1999 23:09:27 -0700 Date: Mon, 16 Aug 1999 10:24:16 -0400 Message-ID: <706.934813456@sss.pgh.pa.us> From: Tom Lane "Dutt H Kalapatapu" writes: > I finally figured out why I am gettting an authentication failure. The > problem was my previous code has the declaration for PgDatabase like > this. > PgDatabase * myDatabase = new PgDatabase("dbname=template1"); > I was running this code on solaris and everything was working fine. I > looked at the PgDatabase class and figured out that we no longer need > that 'dbname='. Now my code looks like this: > PgDatabase * myDatabase = new PgDatabase("template1"); > and I could now run this from the command line. Hmm, that explains a couple of things. The first example (with dbname=) is correct for Postgres 6.5 and later, because PgDatabase's constructor now takes a conninfo string a la PQconnectdb. Older releases used to just take a database name, IIRC. So, you are apparently using a back-rev Postgres on your "new" setup. I had looked at the code in fe_setauthsvc() and was unable to figure out a reason for it to fail (it's almost dead code, anyway) --- but I was looking at the current code. I do seem to recall that pre-6.5 libpq++ would deliver this misleading error message on pretty much any failure to connect, including specifying a wrong database name. I'd recommend upgrading to 6.5.1 ASAP. regards, tom lane