Re: Crash: backup / restore - Mailing list pgadmin-support

From Guillaume Lelarge
Subject Re: Crash: backup / restore
Date
Msg-id 4CBDE007.1050209@lelarge.info
Whole thread Raw
In response to Crash: backup / restore  (Anssi Kääriäinen <anssi.kaariainen@thl.fi>)
Responses Re: Crash: backup / restore  (Anssi Kääriäinen <anssi.kaariainen@thl.fi>)
List pgadmin-support
Le 19/10/2010 13:24, Anssi Kääriäinen a écrit :
> PGAdmin hangs when dumping / restoring a database. I can get to the
> screen that has the pg_dump / pg_restore command, but after that screen
> is displayed there is no progress, and only thing I can do is kill the
> program. (the file dumped to is created but it is empty).
> 
> I thing the bug is related to my pg_hba.conf, relevant lines:
> 
> local   all         all                               trust
> host    all         all         127.0.0.1/32          trust
> host    all         all         xxx.zzz.0.0/16           md5
> 
> I use user "akaariai" which has no password and which is both database
> superuser and my local linux user.
> 
> My PGAdmin connection is set up as follows:
> name: localhost
> host: localhost
> port: 5432
> maintenance_db: postgres
> username: akaariai
> store password checked, restore_env checked. Nothing else set, that
> means also no password set. I can open the connection without any errors.
> 
> The command PGAdmin is trying to run when backup is requested:
> pg_dump --host localhost --port 5432 --username akaariai --format ...
> 
> If I run the command manually, the command asks for password. If I run
> the command without "--host localhost", there is no password prompt.
> Could it be that PGAdmin doesn't expect the server to ask password?
> 

There is no communication between pgAdmin and pg_dump. If pg_dump needs
to ask for a password, you'll surely have your pgAdmin completely blocked.

> Also, if I remove the host=localhost from pgadmin connection
> configuration (leaving host blank), I can backup any DB without errors.
> 

From pgAdmin, I suppose?

> I am using ubuntu 10.04, apt installed postgresql 8.4.5, apt installed
> pgAdmin, version: 1.10.2 rev 8217.
> 

pgAdmin cannot give the password to pg_dump without using the
environment variable (PGPASSWORD)... but it means the password will
appear in the ps output. That won't happen. The only workaround
available is to use a .pgpass file. Which pgAdmin would have created if
you allowed it to store the password.


-- 
Guillaumehttp://www.postgresql.frhttp://dalibo.com


pgadmin-support by date:

Previous
From: Anssi Kääriäinen
Date:
Subject: Crash: backup / restore
Next
From: Guillaume Lelarge
Date:
Subject: Re: Native linux copy/paste