Обсуждение: BUG #12129: questions on exporting data from a database
The following bug has been logged on the website: Bug reference: 12129 Logged by: Rohit Seshadri Email address: rseshadr@uncc.edu PostgreSQL version: Unsupported/Unknown Operating system: Windows 7 Description: Hi, I am trying to extract the data from a database and this is the error that I get. It says that i have to enter a password but I don't know where to enter the password. It would be very helpful if you could walk me through the correct process to export the data from a database. C:\Program Files (x86)\pgAdmin III\1.18\pg_dump.exe --host 172.29.131.1 --port 5432 --username "waverly" --no-password --format tar --verbose --file "C:\Users\Niner\Documents\RTAC 3505 BACKUP.backup" "3530"
If you'll remove --no-password option, then pg_dump should ask you for the password. depesz On Thu, Dec 4, 2014 at 12:31 AM, <rseshadr@uncc.edu> wrote: > The following bug has been logged on the website: > > Bug reference: 12129 > Logged by: Rohit Seshadri > Email address: rseshadr@uncc.edu > PostgreSQL version: Unsupported/Unknown > Operating system: Windows 7 > Description: > > Hi, > I am trying to extract the data from a database and this is the error that > I > get. It says that i have to enter a password but I don't know where to > enter > the password. It would be very helpful if you could walk me through the > correct process to export the data from a database. > > C:\Program Files (x86)\pgAdmin III\1.18\pg_dump.exe --host 172.29.131.1 > --port 5432 --username "waverly" --no-password --format tar --verbose > --file "C:\Users\Niner\Documents\RTAC 3505 BACKUP.backup" "3530" > > > -- > Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgsql-bugs >
On Wed, Dec 3, 2014 at 9:31 PM, <rseshadr@uncc.edu> wrote: > C:\Program Files (x86)\pgAdmin III\1.18\pg_dump.exe --host 172.29.131.1 > --port 5432 --username "waverly" --no-password --format tar --verbose > --file "C:\Users\Niner\Documents\RTAC 3505 BACKUP.backup" "3530" > That is not a bug at all. It should be reported in -admin list. You are given "--no-password" option but your pg_hba.conf is probably not accepting non-password methods. Just remove this argument and pg_dump will prompt you for the password in the terminal. Regards, --=20 Matheus de Oliveira Analista de Banco de Dados Dextra Sistemas - MPS.Br n=C3=ADvel F! www.dextra.com.br/postgres
Matheus de Oliveira wrote > On Wed, Dec 3, 2014 at 9:31 PM, < > rseshadr@ > > wrote: > >> C:\Program Files (x86)\pgAdmin III\1.18\pg_dump.exe --host 172.29.131.1 >> --port 5432 --username "waverly" --no-password --format tar --verbose >> --file "C:\Users\Niner\Documents\RTAC 3505 BACKUP.backup" "3530" >> > > > That is not a bug at all. It should be reported in -admin list. > > You are given "--no-password" option but your pg_hba.conf is probably not > accepting non-password methods. Just remove this argument and pg_dump will > prompt you for the password in the terminal. Or you can use environment variables or .pgpass or change hba.conf to an authentication mechanism that doesn't require a password. But what you cannot do is specify no-password and expect it to work if a password is required but not otherwise supplied. All that option is documented to do is cause the dump to fast-fail instead prompting a non-existent user for a password. Reading the pg_dump documentation would lead you to consider both the above options and this page on considered environment variables. http://www.postgresql.org/docs/9.2/interactive/libpq-envars.html The hba.conf option is the least preferred, least secure, least standard, and most tricky to implement correctly. Also, I'm wondering why your pg_dump path is inside of pgAdmin... David J. -- View this message in context: http://postgresql.nabble.com/BUG-12129-questions-on-exporting-data-from-a-database-tp5829219p5829253.html Sent from the PostgreSQL - bugs mailing list archive at Nabble.com.