Re: Unkillable processes creating millions of tiny temp files

Поиск
Список
Период
Сортировка
От Jan Wieck
Тема Re: Unkillable processes creating millions of tiny temp files
Дата
Msg-id e6280492-a7d7-1d97-f682-c7bba5c300c9@wi3ck.info
обсуждение исходный текст
Список pgsql-general
On 3/5/21 6:57 PM, Tom Lane wrote:

> Not sure how fast that is either.  If you need to do it again, you could
> try manually rm'ing everything under the pgsql_tmp directory before
> letting the postmaster start.
That is actually a strategy that works rather well. mv(1) the tmp 
directory to something date(1) based, then kick off a recursive rm(1) 
-rf on everything named pgsql_tmp_*. That won't miss anything in the 
case the whole server is restarted while the procedure is under way. It 
can cause multiple rm(1) processes trampling over each other, but that 
has no real ill side effects. They are just trying to unlink a file 
another one already did.

Under normal circumstances the rm(1) will clean up while the postmaster 
is already up and possibly created a new pgsql_tmp.


Regards, Jan

-- 
Jan Wieck
Principle Database Engineer
Amazon Web Services



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

Предыдущее
От: Allan Kamau
Дата:
Сообщение: Re: More than one UNIQUE key when matching items..
Следующее
От: Laurenz Albe
Дата:
Сообщение: Re: More than one UNIQUE key when matching items..