Re: How to start a database in ReadOnly mode?

Поиск
Список
Период
Сортировка
От Guillaume Lelarge
Тема Re: How to start a database in ReadOnly mode?
Дата
Msg-id 1310214407.2101.36.camel@laptop
обсуждение исходный текст
Ответ на Re: How to start a database in ReadOnly mode?  ("Greg Sabino Mullane" <greg@turnstep.com>)
Список pgsql-admin
On Sat, 2011-07-09 at 11:58 +0000, Greg Sabino Mullane wrote:
> > Is it possible to start a postgres cluster or 1 postgres database in
> > readonly mode? And - if yes - how can this be done?
>
> Clusterwide: edit postgresql.conf and set
> default_transaction_read_only = on;
>
> No restart needed, just a reload (HUP)
>
> Database-wide:
>
> ALTER DATABASE foobar SET default_transaction_read_only = true;
>

The only issue is that any user can unset this parameter with a SET
query on his session.


--
Guillaume
  http://blog.guillaume.lelarge.info
  http://www.dalibo.com


В списке pgsql-admin по дате отправления:

Предыдущее
От: "Greg Sabino Mullane"
Дата:
Сообщение: Re: How to start a database in ReadOnly mode?
Следующее
От: Uwe Bartels
Дата:
Сообщение: using explain output within pgsql