Re: pg_tablespace_size()

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pg_tablespace_size()
Дата
Msg-id 29645.1192209204@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: pg_tablespace_size()  (Magnus Hagander <magnus@hagander.net>)
Ответы Re: pg_tablespace_size()  (Magnus Hagander <magnus@hagander.net>)
Список pgsql-hackers
Magnus Hagander <magnus@hagander.net> writes:
> Tom Lane wrote:
>> * Just remove the above-quoted lines.  Superusers should be allowed to
>> shoot themselves in the foot.  (I'm not actually sure that there would
>> be any bad consequences from putting an ordinary table into pg_global
>> anyway.

> Is there ever *any* reason for doing this?

Probably not a good one, and I suspect there would be some funny
misbehaviors if you were to clone the database containing the table.
The table would be physically shared but logically not.

What I'm inclined to do about it is is adopt my suggestion #2 (move the
location of the defense), since "permission denied" for a superuser is
a pretty unhelpful error message anyway.

>> * Decide that we should allow anyone to do pg_tablespace_size('pg_global')
>> and put in a special wart for that in dbsize.c.  This wasn't part of
>> the original agreement but maybe there's a case to be made for it.

> That's pretty much the same thing, right?

Well, no, I was suggesting that we might want to special-case pg_global
as a tablespace that anyone (superuser or no) could get the size of.
This is actually independent of whether we change the aclmask behavior.
        regards, tom lane


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

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: Re: pg_tablespace_size()
Следующее
От: Magnus Hagander
Дата:
Сообщение: Re: pg_tablespace_size()