Re: In a fix: lost superuser

From: jdassen(at)cistron(dot)nl (J(dot)H(dot)M(dot) Dassen (Ray))
To: pgsql-general(at)postgresql(dot)org
Subject: Re: In a fix: lost superuser
Date: 2001-05-14 07:39:25
Message-ID: slrn9fv2td.m6.jdassen@odin.cistron-office.nl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Ken <mailinglists(at)creason(dot)com> wrote:
> Is there any way to reset the superuser password if it has been lost?

I haven't tried it, but I guess the following should work:
- As root, edit the pg_hba.conf to allow access without the postgres
superuser password
"host all 127.0.0.1 255.255.255.255 trust"
- connect to postgres
"psql -U postgres template1"
- put a new password on the postgres user
"alter user postgresql with password 'fubar'"
- restore the old pg_hba.conf

HTH,
Ray
--
NATUURLIJK krijg je er geen signaal doorheen - het is *dark* fibre.
jtv

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Stefan Loidl 2001-05-14 07:57:15 Problem with referential integrity and inherited tables in 7.1.1
Previous Message Holger Klawitter 2001-05-14 07:14:38 Re: In a fix: lost superuser