Database: PostgreSQL 9.0 Client: Windows 7 Server Windows 2008, 64-bit
I am trying to remotely connect to a PostgreSQL instance to execute pg_dump on my local machine.
Everything works from my client machine, except that I need to enter a password in the password input line, and I would eventually want to do this with a script.
I followed the instructions here:
http://www.postgresql.org/docs/current/static/libpq-pgpass.html
But that does not work.
Recall that I created a file on the server: C:/Users/postgres/AppData/postgresql/pgpass.confwhere PostgreSQL is the db user.
The file contains one line with the following data:
\*:5432:\*postgres:[mypassword]
I also tried to replace each *with [localhost|myip]and [mydatabasename]respectively.
:
pg_dump -h <myip> -U postgres -w [mydbname] > [mylocaldumpfile]
, -w, , AppData .
:
: fe_sendauth: .
, Windows PostgreSQL, .