Re: restored over postgres database
От | Bill Moran |
---|---|
Тема | Re: restored over postgres database |
Дата | |
Msg-id | 20081203120023.0f90e7fd.wmoran@collaborativefusion.com обсуждение исходный текст |
Ответ на | Re: restored over postgres database ("Scott Marlowe" <scott.marlowe@gmail.com>) |
Список | pgsql-general |
In response to "Scott Marlowe" <scott.marlowe@gmail.com>: > On Wed, Dec 3, 2008 at 9:38 AM, Kevin Duffy <KD@wrinvestments.com> wrote: > > Hello: > > > > On a newly installed PostgreSQL server I made the mistake of restoring over > > the postgres database. > > > > Which I made me feel very silly and brought up a couple of questions. > > > > a) What is the postgres database used for? > > By default, nothing usually. Whatever you're using it for is usually it. If he's talking about the _database_ called postgres, it's in the cluster to provide an unused database that applications can connection to by default. > > b) How can I restore the postgres database to a pristine state? > > shut down postgres > delete everything in the $PGDATA directory (or whatever comes after -D > when it starts up) > run initdb > start postgres > > All should now be clean and fresh. Assuming he meant the entire cluster and not just the postgres database. If the latter, a DROP/CREATE will return it to the normal state. -- Bill Moran Collaborative Fusion Inc. http://people.collaborativefusion.com/~wmoran/ wmoran@collaborativefusion.com Phone: 412-422-3463x4023
В списке pgsql-general по дате отправления: