How to pg_dump the database for backup?

OS: Ubuntu Server 12.04 LTS

PostgreSQL 9.1

I've logged in via SSH.

login user: nuxeo

Nuxeo: 5.5 ( installed via apt-get )

I've tried several commands and/or psql but can't find and dump the nuxeo db.

$ sudo su - postgres

$ psql

# SELECT * FROM pg_user;

I only see 1 user: postgres

# \l

I only see postgres, template0 and template1

Where are nuxeo user and db?

Any help?

0 votes

1 answers

3499 views

ANSWER



Hi!

If you are running a default installation, it's probably because the nuxeodb postgres server is listening on port 5433. If you connect with :

psql -p 5433

then you should see more infos :)

And a command like :

pg_dump -p 5433 -f yourdumpfile.dump nuxeo

should give you what you are looking for.

2 votes



Thanks!!! :-)
05/18/2012