Thread (27 messages) flat view 27 messages, 11 authors, 2018-11-25

Re: [PATCH] Add /proc/pid_generation

From: Matthew Wilcox <willy@infradead.org>
Date: 2018-11-21 20:31:58
Also in: linux-doc, lkml

On Wed, Nov 21, 2018 at 12:14:44PM -0800, Daniel Colascione wrote:
This change adds a per-pid-namespace 64-bit generation number,
incremented on PID rollover, and exposes it via a new proc file
/proc/pid_generation. By examining this file before and after /proc
enumeration, user code can detect the potential reuse of a PID and
restart the task enumeration process, repeating until it gets a
coherent snapshot.

PID rollover ought to be rare, so in practice, scan repetitions will
be rare.
Then why does it need to be 64-bit?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help