tags:

views:

157

answers:

1

I'm using Windows XP and I've installed PostgreSQL 8.3.5-2. I can create databases via pgAdmin but not from Powershell. When I try, I get the following error:

createdb: could not connect to database postgres: FATAL:  password authentication failed for user "gvkv"

where postgres is the server's only user account and "gvkv" is the account I work under. I've tried creating a separate account just for the the server and installing under that account but the installer keeps crashing.

More fundamentally, I want to create some Powershell scripts to automate various tasks of database creation and administration but at this point, I can't even create a data store!

+1  A: 

I think this is because you're connecting via the IP of the computer and not localhost. Most databases make a difference between connections to the local IP address (even if this is from a local application) and localhost: the first is an external connection and has to be enabled and the second is a local connection and is allowed.

So try to connect to localhost instead and see if that works.

Frans Bouma