PostgreSQL Database Dump and Restore: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
Line 8: Line 8:


=Procedure=
=Procedure=
==Dump the Database==
===Get Access to Host Database is Running On===
<tt>pg_dump</tt> utility needs to run on the host the database to be dumped runs on.
===Dump the Database===
pg_dump -U <''database-user-name''> <''database-name''> >

Revision as of 18:19, 21 December 2018

Internal

Overview

This article describes the dump and restore procedure for a PostgreSQL database. The procedure can be used in various situations, such as when the database needs to be back up, or transferred into another physical RDBMS.

Procedure

Dump the Database

Get Access to Host Database is Running On

pg_dump utility needs to run on the host the database to be dumped runs on.

Dump the Database

pg_dump -U <database-user-name> <database-name> >