Skip site navigation (1) Skip section navigation (2)

Re: moving a single database

From: Richard Broersma Jr <rabroersma(at)yahoo(dot)com>
To: Tom Allison <tallison(at)tacocat(dot)net>, pgsql-novice(at)postgresql(dot)org
Subject: Re: moving a single database
Date: 2006-11-19 03:23:25
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
> I want to move just one database from server A to server B.
> The files under /var/lib/postgresql/8.1/ are not exactly jumping out and telling 
> me which files belong to which database.
> So, how do you move a database (not the entire postgresql installation)?
> Considering the existence of things like triggers and sequences -- will a simple 
>   dump/restore be sufficient?

you are going to pg_dumpall.  It will get all schema, table, rule, trigger, and data into a sql
script file.  It will also get the user, group, and other cluster level entities and definitions.


Richard Broersma Jr.

In response to

pgsql-novice by date

Next:From: Tom AllisonDate: 2006-11-19 15:34:21
Subject: SSL
Previous:From: Tom AllisonDate: 2006-11-18 23:50:15
Subject: moving a single database

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group