Re: danger of stats_temp_directory = /dev/shm

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: danger of stats_temp_directory = /dev/shm
Дата
Msg-id 20130819180437.GF9264@eldon.alvh.no-ip.org
обсуждение исходный текст
Ответ на Re: danger of stats_temp_directory = /dev/shm  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Ответы Re: danger of stats_temp_directory = /dev/shm  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Alvaro Herrera wrote:

> > In addition to that, it might be a good idea to do what the comment in the
> > code suggests, namely do more than zero checking on each file name to try
> > to make sure it looks like a stats temp file name that we'd generate
> > before we delete it.  The ownership/permissions test wouldn't be enough
> > to prevent you from pointing at, say, ~postgres and thereby losing some
> > files you'd rather not.
>
> This seems pretty simple to do; see second attachment.  (It would delete
> files named, "db_1234.tmpfoobar", that is, valid names with suffixes,
> but I can't see that being a problem).  (I haven't really tested this
> part at all.)

Here's the second attachment.

--
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

Вложения

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

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Re: UNNEST with multiple args, and TABLE with multiple funcs
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: pgstat_reset_remove_files ignores its argument