Saturday, March 05, 2011

Postgres Backup CentOS

#su postgres

$ pg_dump -Ft mydb > db.tar
$ pg_restore -d newdb db.tar


References:
[1]http://linux.die.net/man/1/pg_dump
[2]http://linux.die.net/man/1/pg_restore

No comments:

Python3 version alternatives and virtual environments

Solving multiple python installation:   sudo update-alternatives --install /usr/ bin /python3 python3 /usr/ bin /python3 .5 1 sudo update...