PDA

View Full Version : Postgres Password Issues



hannah
02-13-2011, 08:08 PM
Hi,

I tried to reinstall postgress on my computer bu't can't remember the windows super user password. What should I do ?
Thanks for your help.

olliepower
02-13-2011, 10:47 PM
1) Go to C:\Program Files\PostgreSQL\8.x\data, move the pg_hba file to your Desktop and open it with notepad.
2) Scroll to the bottom and change all md5 to trust. Save and close the file.
3) Move the file back to the data folder.
4) Restart the PostgreSQL service: Control Panel -> Administrative Tools -> Services

HM will accept any password now.

hannah
02-14-2011, 03:07 AM
Hi. Thanks for answering so fast.

As I deleted postgres once, the pg_hba file does not exist anymore. I'm on vista.

netsrak
02-14-2011, 04:41 AM
Standard postgresql passwords are postgrespass, postgres and dbpass.

If none of them works you need to delete the postgres user. Open a command box as administrator and type
net user postgres /delete

After successful completion you can assign a new postgres password during the next installation

hannah
02-14-2011, 05:51 AM
Thanks, it works !
New problem, at the end at the installation postgres says : " Problem running post install step. Installation may not complete correctly. The database cluster initialisation failed. "

And then when I try to launch HM : Failed to etablish connection to ...

What should I do now ?

Thanks a lot.

Patvs
02-15-2011, 05:47 AM
The secondary logon service is a standard windows service which is available on every windows computer. In the latest versions it is not started automatically. You need to start it via control panel > administrative tools > services. Starting it once should insure it works in the future also.


Can you install a different version from PostgreSQL: The world's most advanced open source database (http://www.postgresql.org)
If 8.4.7 has the same error, try 8.2.x and install it to a different port like 5433.