I run these commands automatically every night:
vacuumdb -a -z -U postgres
reindexdb -a -U postgres
Is there a way to temporarily disable all other
connections to Postgres until these operations are
complete? The operations take a while (about 20
minutes) and connections really pile up, sometimes
crashing the server.