Postgres: Copy a database


November 17, 2012

Databases, Postgres

No Comment

For backup and development reasons a copy of a postgres database on the same system is often used. This is not a big problem and can be done directly as a SQL statement: [crayon-59eb01d9d97d9491472751/] in your favorite console (psql, pgadmin, etc). There is one thing to remember, if you do a template copy this can […]

Read More

Postgres: Remote copy a database between two machines using ssh

Sometimes it might be useful to copy a postgres database between two systems. This is not a big hazel and can be done with a simple one-liner (Port 22): [crayon-59eb01d9da67c869673133/] and even if your ssh connection uses a different port (1234) you are good to go: [crayon-59eb01d9da682992506092/]

Read More


  • An error has occurred, which probably means the feed is down. Try again later.