[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: increase kernel.pid_max?



On Sun, 2020-03-01 at 09:24 +0800, Ian Campbell wrote:
> On Sat, 2020-02-29 at 20:14 +0100, Harald Dunkel wrote:
> > Hi folks,
> > 
> > looking at the number of cores and highly parallel applications
> > I wonder if it would be reasonable to increase the default
> > kernel.pid_max (currently 0x8000) to lets say 0x3fffff?
> > 
> > Do you expect negative side effects?
> 
> It's already 0x400000 on my machine and everything is fine. I haven't
> (knowingly) tweaked anything so I guess this is the default on recent
> machines, this laptop is running 5.4.0-3-amd64 (testing userspace,
> although not updated for a little bit).
> 
> I can't actually find when/where this changed in recent history -- I've
> only noticed these large pids in recent months, but it's entirely
> possible I'm simply not that observant.

This was a change in systemd 243:

        * On 64 bit systems, the "kernel.pid_max" sysctl is now bumped to
          4194304 by default, i.e. the full 22bit range the kernel allows, up
          from the old 16bit range.

Ben.

> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=72680a191b934377430032f93af15ef50aafb3a8 was in 2010 and a 2.6.x
> kernel.
> 
> Ian.
> 
-- 
Ben Hutchings
It is a miracle that curiosity survives formal education.
                                                      - Albert Einstein

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: