lkml.org 
[lkml]   [2000]   [Feb]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: PID Wrap <strangeness>
On Tue, 22 Feb 2000, Richard B. Johnson wrote:

>Date: Tue, 22 Feb 2000 17:31:51 -0500 (EST)
>From: Richard B. Johnson <root@chaos.analogic.com>
>To: Linux kernel <linux-kernel@vger.rutgers.edu>
>Subject: PID Wrap <strangeness>
>
>
>On Linux 2.3.41 (haven't checked others) when the PID wraps past
>32,767 the next PID is 300. It is not the next-available low one.
>
>Does anybody know why?

My guess is that it is a sort of optimization. Most if not all
system services end up with a PID < 300 at boot time. As long as
they don't get killed and restarted, they'll keep that PID.
Userland processes will come and go, and as such most PID's after
300 will be free to use again if PID just wrapped, whereas most
PID's under 300 have a higher chance of allready being used.

That is my guess anyways..

TTYL

--
Mike A. Harris Linux advocate
Computer Consultant GNU advocate
Capslock Consulting Open Source advocate

Suspicious Anagram #4:
Word: PRESIDENT CLINTON OF THE USA
Anagram: TO COPULATE HE FINDS INTERNS


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:56    [from the cache]
©2003-2011 Jasper Spaans