Restoring a database problem

From: Glen Eustace <geustace(at)godzone(dot)net(dot)nz>
To: pgsql-general(at)postgresql(dot)org
Subject: Restoring a database problem
Date: 2020-10-01 00:00:21
Message-ID: e5b66a06-8b3c-8ff7-7e23-7962026a950c@godzone.net.nz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I have had to do this so rarely and it has almost always been in a bit
of a panic so may well be missing something really obvious.

What I want to know is how to quiese a database to that I can restore it.

I need to close all existing connections and the prevent
people/processes from connecting again until the restore has completed.

Currently I have been logging into a bunch of servers and stopping
various daemons, then on the database server killing processes until the
database is apparently idle then dropping the database and doing the
restore. Then restarting the daemons etc. I am sure I am not doing this
the right way so advice gratefully received.

--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Glen Eustace,
GodZone Internet Services, a division of AGRE Enterprises Ltd.,
P.O. Box 8020, Palmerston North, New Zealand 4446 Ph +64 6 357 8168, Mob
+64 27 542 4015

“Specialising in providing low-cost professional Internet Services since
1997"

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2020-10-01 00:11:00 Re: Restoring a database problem
Previous Message Michael Lewis 2020-09-30 22:15:46 Re: Database logins taking longer and longer, showing up as "authentication" in ps(1)