Re: /proc/self/oom_adj is deprecated in newer Linux kernels

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: /proc/self/oom_adj is deprecated in newer Linux kernels
Дата
Msg-id 31348.1402415537@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: /proc/self/oom_adj is deprecated in newer Linux kernels  (andres@anarazel.de (Andres Freund))
Ответы Re: /proc/self/oom_adj is deprecated in newer Linux kernels
Re: /proc/self/oom_adj is deprecated in newer Linux kernels
Список pgsql-hackers
andres@anarazel.de (Andres Freund) writes:
> On 2014-06-10 11:20:28 -0400, Tom Lane wrote:
>> Maybe I'm mistaken, but I thought once the fork_process code has reset our
>> process's setting to zero it's not possible to lower it again (without
>> privileges we'd not have).

> No, doesn't look that way. It's possible to reset it to the value set at
> process start. So unless we introduce double forks for every backend
> start it can be reset by ordinary processes.

That's kind of annoying --- I wonder why they went to the trouble of doing
that?  But anyway, it's probably not worth the cost of double-forking to
prevent it.  I still say though that this is not a reason to make it as
easy as change-a-GUC to break the intended behavior.

Robert's idea of having the start script set an environment variable to
control the OOM adjustment reset seems like it would satisfy my concern.
        regards, tom lane



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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: /proc/self/oom_adj is deprecated in newer Linux kernels
Следующее
От: Gurjeet Singh
Дата:
Сообщение: Re: /proc/self/oom_adj is deprecated in newer Linux kernels