phpPgAdmin exporting empty SQL dump?

I'm trying to export a PostgreSQL database from phpPgAdmin and for some reason it's dumping out an empty SQL file.

The database is definitely not empty.

To export it I am clicking on the database, then export, then selecting structure and data.

Any idea why this would be? Thanks


Solution 1:

you need to modify your dbexport.php in /usr/share/phppgadmin (on Ubuntu)

modify line from passthru($cmd); to echo passthru($cmd); modify line $cmd = $exe . " -i"; to $cmd = $exe;

it will be enough. Cause parameter -i seems to be deprecated in postgres 9.5 , he gave error for me.

Solution 2:

I managed to export it from the command line using:

./pg_dump -U postgres -c -f /htdocs/databasename.sql databasename