Re: lock a database from new connections, without modifying

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Is that possible? I've checked the docs for 8.1, and am not finding anything, nor anything in contrib ... the best I've been able to think of so far is to modify pg_hba.conf to not allow new connections for the duration of the operations I need to perform (drop and create a database) ...

Just in case ...

update pg_catalog.pg_database set datallowconn = false where datname = '...';

http://archives.postgresql.org/pgsql-docs/2004-11/msg00015.php
http://www.postgresql.org/docs/8.1/interactive/manage-ag-templatedbs.html


My twopence.

Ben K.
Developer
http://benix.tamu.edu


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux