Password authentication failing
Password authentication failing
Hi
I installed Pgadmin3 version 1.12.3 on Linux Mint 12 which also has PostgreSQL 8.4 installed.
It all worked fine and I was able to look at the database.
Then I went away for a few days, came back and now have a problem connecting to PostgreSQL
the error is:
Error connecting to the server: FATAL: password authentication failed for user "postgres"
FATAL: password authentication failed for user "postgres"
Seems simple enough! but I retype the password and no joy.
I have another application that uses PostgreSQL (LedgerSMB) and it works fine.
After some research I changed the password using :
ALTER USER postgres PASSWORD 'newPassword';
in psql
this also does not work
I also edited pg_hba.comf and replaced the word 'ident' with 'trust' in the first line.
I restarted the postgres server and still no joy.
There has to be something simple that I am missing but I can't see it!
any help would be appreciated
thanks
Bill
Re: Password authentication failing
On Thu, 2011-12-29 at 16:31 +0000, Bill Appelbe wrote: > Hi > I installed Pgadmin3 version 1.12.3 on Linux Mint 12 which also has > PostgreSQL 8.4 installed. > > It all worked fine and I was able to look at the database. > Then I went away for a few days, came back and now have a problem > connecting to PostgreSQL > the error is: > Error connecting to the server: FATAL: password authentication failed for > user "postgres" > FATAL: password authentication failed for user "postgres" > > Seems simple enough! but I retype the password and no joy. > I have another application that uses PostgreSQL (LedgerSMB) and it works > fine. > > After some research I changed the password using : > ALTER USER postgres PASSWORD 'newPassword'; > in psql > this also does not work > > I also edited pg_hba.comf and replaced the word 'ident' with 'trust' in the > first line. > I restarted the postgres server and still no joy. > > There has to be something simple that I am missing but I can't see it! > any help would be appreciated > The only reason I see is that you're not connecting to the same server. -- Guillaume http://blog.guillaume.lelarge.info http://www.dalibo.com PostgreSQL Sessions #3: http://www.postgresql-sessions.org
Re: Password authentication failing
The only reason I see is that you're not connecting to the same server.On Thu, 2011-12-29 at 16:31 +0000, Bill Appelbe wrote:
> Hi
> I installed Pgadmin3 version 1.12.3 on Linux Mint 12 which also has
> PostgreSQL 8.4 installed.
>
> It all worked fine and I was able to look at the database.
> Then I went away for a few days, came back and now have a problem
> connecting to PostgreSQL
> the error is:
> Error connecting to the server: FATAL: password authentication failed for
> user "postgres"
> FATAL: password authentication failed for user "postgres"
>
> Seems simple enough! but I retype the password and no joy.
> I have another application that uses PostgreSQL (LedgerSMB) and it works
> fine.
>
> After some research I changed the password using :
> ALTER USER postgres PASSWORD 'newPassword';
> in psql
> this also does not work
>
> I also edited pg_hba.comf and replaced the word 'ident' with 'trust' in the
> first line.
> I restarted the postgres server and still no joy.
>
> There has to be something simple that I am missing but I can't see it!
> any help would be appreciated
>
--
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com
PostgreSQL Sessions #3: http://www.postgresql-sessions.org
Bill
Re: Password authentication failing
On Thu, 2011-12-29 at 17:00 +0000, Bill Appelbe wrote: > > > On Thu, Dec 29, 2011 at 4:47 PM, Guillaume Lelarge > wrote: > On Thu, 2011-12-29 at 16:31 +0000, Bill Appelbe wrote: > > Hi > > I installed Pgadmin3 version 1.12.3 on Linux Mint 12 which > also has > > PostgreSQL 8.4 installed. > > > > It all worked fine and I was able to look at the database. > > Then I went away for a few days, came back and now have a > problem > > connecting to PostgreSQL > > the error is: > > Error connecting to the server: FATAL: password > authentication failed for > > user "postgres" > > FATAL: password authentication failed for user "postgres" > > > > Seems simple enough! but I retype the password and no joy. > > I have another application that uses PostgreSQL (LedgerSMB) > and it works > > fine. > > > > After some research I changed the password using : > > ALTER USER postgres PASSWORD 'newPassword'; > > in psql > > this also does not work > > > > I also edited pg_hba.comf and replaced the word 'ident' with > 'trust' in the > > first line. > > I restarted the postgres server and still no joy. > > > > There has to be something simple that I am missing but I > can't see it! > > any help would be appreciated > > > > > The only reason I see is that you're not connecting to the > same server. > > > -- > Guillaume > http://blog.guillaume.lelarge.info > http://www.dalibo.com > PostgreSQL Sessions #3: http://www.postgresql-sessions.org > > > It is all to 127.0.0.1 there is no other PostgreSQL installation on > the network > OK. Then, tell us exactly how you try to connect to your PostgreSQL database, the exact error message you get, and give us the whole pg_hba.conf file. -- Guillaume http://blog.guillaume.lelarge.info http://www.dalibo.com PostgreSQL Sessions #3: http://www.postgresql-sessions.org
Re: Password authentication failing
TRY alter user postgres with password “NNNNNNNN “;
Julio Elizondo
De: pgadmin-support-owner@postgresql.org [mailto:pgadmin-support-owner@postgresql.org] En nombre de Bill Appelbe
Enviado el: jueves, 29 de diciembre de 2011 02:01 p.m.
Para: Guillaume Lelarge
CC: pgadmin-support@postgresql.org
Asunto: Re: [pgadmin-support] Password authentication failing
On Thu, Dec 29, 2011 at 4:47 PM, Guillaume Lelarge <guillaume@lelarge.info> wrote:
On Thu, 2011-12-29 at 16:31 +0000, Bill Appelbe wrote:
> Hi
> I installed Pgadmin3 version 1.12.3 on Linux Mint 12 which also has
> PostgreSQL 8.4 installed.
>
> It all worked fine and I was able to look at the database.
> Then I went away for a few days, came back and now have a problem
> connecting to PostgreSQL
> the error is:
> Error connecting to the server: FATAL: password authentication failed for
> user "postgres"
> FATAL: password authentication failed for user "postgres"
>
> Seems simple enough! but I retype the password and no joy.
> I have another application that uses PostgreSQL (LedgerSMB) and it works
> fine.
>
> After some research I changed the password using :
> ALTER USER postgres PASSWORD 'newPassword';
> in psql
> this also does not work
>
> I also edited pg_hba.comf and replaced the word 'ident' with 'trust' in the
> first line.
> I restarted the postgres server and still no joy.
>
> There has to be something simple that I am missing but I can't see it!
> any help would be appreciated
>
The only reason I see is that you're not connecting to the same server.
--
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com
PostgreSQL Sessions #3: http://www.postgresql-sessions.org
It is all to 127.0.0.1 there is no other PostgreSQL installation on the network
Bill
Este correo electrónico puede contener información confidencial y protegida legalmente bajo secreto profesional y/o financiero. La información esta dirigida solamente a la persona o entidad indicada como destinatario y su acceso por cualquier otra persona no esta autorizado.
Si ud. ha recibido este mensaje electrónico por error, por favor infórmeselo al remitente y bórrelo. Los conceptos y opiniones contenidos en este mail corresponden al autor del mensaje y no necesariamente coinciden con las de Distribuidora de Gas Cuyana S.A.
Muchas Gracias.
Distribuidora de Gas Cuyana S.A.
Re: Password authentication failing
OK. Then, tell us exactly how you try to connect to your PostgreSQLOn Thu, 2011-12-29 at 17:00 +0000, Bill Appelbe wrote:
>
>
> On Thu, Dec 29, 2011 at 4:47 PM, Guillaume Lelarge
> <guillaume@lelarge.info> wrote:
> On Thu, 2011-12-29 at 16:31 +0000, Bill Appelbe wrote:
> > Hi
> > I installed Pgadmin3 version 1.12.3 on Linux Mint 12 which
> also has
> > PostgreSQL 8.4 installed.
> >
> > It all worked fine and I was able to look at the database.
> > Then I went away for a few days, came back and now have a
> problem
> > connecting to PostgreSQL
> > the error is:
> > Error connecting to the server: FATAL: password
> authentication failed for
> > user "postgres"
> > FATAL: password authentication failed for user "postgres"
> >
> > Seems simple enough! but I retype the password and no joy.
> > I have another application that uses PostgreSQL (LedgerSMB)
> and it works
> > fine.
> >
> > After some research I changed the password using :
> > ALTER USER postgres PASSWORD 'newPassword';
> > in psql
> > this also does not work
> >
> > I also edited pg_hba.comf and replaced the word 'ident' with
> 'trust' in the
> > first line.
> > I restarted the postgres server and still no joy.
> >
> > There has to be something simple that I am missing but I
> can't see it!
> > any help would be appreciated
> >
>
>
> The only reason I see is that you're not connecting to the
> same server.
>
>
> --
> Guillaume
> http://blog.guillaume.lelarge.info
> http://www.dalibo.com
> PostgreSQL Sessions #3: http://www.postgresql-sessions.org
>
>
> It is all to 127.0.0.1 there is no other PostgreSQL installation on
> the network
>
database, the exact error message you get, and give us the whole
pg_hba.conf file.
I fill in the window that appears Name =test, Host =127.0.0.1 the next few are default
(port 5432, Maintaince DB and username both 'postgres') and enter password, click 'ok'
a window comes up warning me of storing password on the disk click 'ok'
Then I get the error above (it was copy and pasted)
my pg_hba.conf:
# Database administrative login by Unix domain socket
local all postgres ident
# TYPE DATABASE USER CIDR-ADDRESS METHOD
# "local" is for Unix domain socket connections only
local all all ident
# IPv4 local connections:
host all all 127.0.0.1/32 md5
# IPv6 local connections:
host all all ::1/128 md5
thanks for your help
Altering user postgres with password 'NNNNNNN';
made no difference
Bill
Re: Password authentication failing
many thanks
Bill
Change the 2 md5 to trust and all will workFrom: Bill Appelbe <bappelbe@gmail.com>
To: Guillaume Lelarge <guillaume@lelarge.info>
Cc: pgadmin-support@postgresql.org
Sent: Thursday, December 29, 2011 2:23 PM
Subject: Re: [pgadmin-support] Password authentication failingOn Thu, Dec 29, 2011 at 5:04 PM, Guillaume Lelarge <guillaume@lelarge.info> wrote:OK. Then, tell us exactly how you try to connect to your PostgreSQLOn Thu, 2011-12-29 at 17:00 +0000, Bill Appelbe wrote:
>
>
> On Thu, Dec 29, 2011 at 4:47 PM, Guillaume Lelarge
> <guillaume@lelarge.info> wrote:
> On Thu, 2011-12-29 at 16:31 +0000, Bill Appelbe wrote:
> > Hi
> > I installed Pgadmin3 version 1.12.3 on Linux Mint 12 which
> also has
> > PostgreSQL 8.4 installed.
> >
> > It all worked fine and I was able to look at the database.
> > Then I went away for a few days, came back and now have a
> problem
> > connecting to PostgreSQL
> > the error is:
> > Error connecting to the server: FATAL: password
> authentication failed for
> > user "postgres"
> > FATAL: password authentication failed for user "postgres"
> >
> > Seems simple enough! but I retype the password and no joy.
> > I have another application that uses PostgreSQL (LedgerSMB)
> and it works
> > fine.
> >
> > After some research I changed the password using :
> > ALTER USER postgres PASSWORD 'newPassword';
> > in psql
> > this also does not work
> >
> > I also edited pg_hba.comf and replaced the word 'ident' with
> 'trust' in the
> > first line.
> > I restarted the postgres server and still no joy.
> >
> > There has to be something simple that I am missing but I
> can't see it!
> > any help would be appreciated
> >
>
>
> The only reason I see is that you're not connecting to the
> same server.
>
>
> --
> Guillaume
> http://blog.guillaume.lelarge.info
> http://www.dalibo.com
> PostgreSQL Sessions #3: http://www.postgresql-sessions.org
>
>
> It is all to 127.0.0.1 there is no other PostgreSQL installation on
> the network
>
database, the exact error message you get, and give us the whole
pg_hba.conf file.I open pgAdmin and go to File - Add Server
I fill in the window that appears Name =test, Host =127.0.0.1 the next few are default
(port 5432, Maintaince DB and username both 'postgres') and enter password, click 'ok'
a window comes up warning me of storing password on the disk click 'ok'
Then I get the error above (it was copy and pasted)
my pg_hba.conf:
# Database administrative login by Unix domain socket
local all postgres ident
# TYPE DATABASE USER CIDR-ADDRESS METHOD
# "local" is for Unix domain socket connections only
local all all ident
# IPv4 local connections:
host all all 127.0.0.1/32 md5
# IPv6 local connections:
host all all ::1/128 md5
thanks for your help
Altering user postgres with password 'NNNNNNN';
made no difference
Bill
Re: Password authentication failing
On Thu, 2011-12-29 at 17:47 +0000, Bill Appelbe wrote: > Solved It would be great to say how you solved it. It may help other users. -- Guillaume http://blog.guillaume.lelarge.info http://www.dalibo.com PostgreSQL Sessions #3: http://www.postgresql-sessions.org
Re: Password authentication failing
"Change the 2 md5 to trust and all will work"
in the pg_hba.conf file
thanks again Francisco
Bill
On Thu, 2011-12-29 at 17:47 +0000, Bill Appelbe wrote:
> Solved
It would be great to say how you solved it. It may help other users.
--
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com
PostgreSQL Sessions #3: http://www.postgresql-sessions.org
Re: Password authentication failing
On Fri, 2011-12-30 at 08:50 +0000, Bill Appelbe wrote: > Solved using the recommendation: > "Change the 2 md5 to trust and all will work" > in the pg_hba.conf file > You do know what trust means, right? no check of any password? meaning anyone can connect to your database with the highest permissions? -- Guillaume http://blog.guillaume.lelarge.info http://www.dalibo.com PostgreSQL Sessions #3: http://www.postgresql-sessions.org
Re: Password authentication failing
It also does not answer why it worked last week and not now
Bill
On Fri, 2011-12-30 at 08:50 +0000, Bill Appelbe wrote:You do know what trust means, right? no check of any password? meaning
> Solved using the recommendation:
> "Change the 2 md5 to trust and all will work"
> in the pg_hba.conf file
>
anyone can connect to your database with the highest permissions?
--
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com
PostgreSQL Sessions #3: http://www.postgresql-sessions.org
Re: Password authentication failing
On Fri, 2011-12-30 at 09:42 +0000, Bill Appelbe wrote: > Are there any other suggestions? > It also does not answer why it worked last week and not now > Well, no because the steps you show above seem the good ones. But saying your problem is solved by using trust is wrong. The only suggestion I have is to look into the pgadmin log file, and see the connection string. You may need to make pgadmin log more to have this information (probably debug level). -- Guillaume http://blog.guillaume.lelarge.info http://www.dalibo.com PostgreSQL Sessions #3: http://www.postgresql-sessions.org