Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3422086imu; Wed, 7 Nov 2018 10:04:42 -0800 (PST) X-Google-Smtp-Source: AJdET5fC368fJu8u1+6xl0WRRtzQsmKZZu4/HZrMkHNAsii6PXLg2zo5xOInyR/OJWnI6P47OsmI X-Received: by 2002:a63:9809:: with SMTP id q9mr1005130pgd.109.1541613882462; Wed, 07 Nov 2018 10:04:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541613882; cv=none; d=google.com; s=arc-20160816; b=oBrxxmAq3VsSjrpe5xpV864lwANb8u3Giz1cEJf2gBp1Kt5JteCr2qN9wi0bqUpO2Q NOOX7CaKrTiC+5fhW66B1Hv0ypxQwEbop5WIVXUtYW/AGbDvIyRlvxysdKcPzh6oYZ8M qoqkChFmFEdKavgbkGFFSCym6IV53aP3cjC2+zaqdU0sWA72/TELQhlyvOexZ/1eP8Sf di7xqnbA+ctzZcR3zyLKJdug4F5VzsHN2g1HckAQMJmbDaF3emLMCijLk6xkQKpBAQzr OWn5bATGZCqTeC1jV/l4djsA8/UaSTLcpQQs651/uznO7bcxbppPMShkFnwuq2bl8zZB XGCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature; bh=WygdfWgc82JLORm6/ybR+mPW6gq6639PAYDpVjtVbrQ=; b=Ys71NnMtWv6Xj/W7ineHQIuy3FLOYcMpq03JUBttHSqIeaSlaScq9++3Hhtd9nPTjm yKdstPOVFLNqIK6A2XldfniQyZzvvCrrw2BhQS6N8b/Hzn4jQ3F8+ozluOdIxEwHx58r VZc662L3PGgptdlQGB8QMeQARyunEGVN7SUs4VlRuN4G4QKKFtck86zM5QBFRtp2mxIq H9xJlFLhM6X8bxnyiJ8iTYlMH/qQO22gvHz19erPgZwwl254b02izInjmNrtUbZKzARi BxI1+Jl0tZhHw65vBiNYCAolRy3OMToFrnhV/QMCSm/NnWKTDabVJl8Mlcs4HJz7AqHE xW4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=e0Xys081; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f91-v6si1336467plf.324.2018.11.07.10.04.26; Wed, 07 Nov 2018 10:04:42 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=e0Xys081; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731246AbeKHBlE (ORCPT + 99 others); Wed, 7 Nov 2018 20:41:04 -0500 Received: from mail-vk1-f194.google.com ([209.85.221.194]:39655 "EHLO mail-vk1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727372AbeKHBlD (ORCPT ); Wed, 7 Nov 2018 20:41:03 -0500 Received: by mail-vk1-f194.google.com with SMTP id o10-v6so3817674vki.6 for ; Wed, 07 Nov 2018 08:10:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=WygdfWgc82JLORm6/ybR+mPW6gq6639PAYDpVjtVbrQ=; b=e0Xys081855tteOPeAQ63WgrsEJPcuAfBlonEt+hCPRp6wBEAx78wdpi2Yef9Z65Qq R+g2L7t0lIVcpiEUZM4bPsVT9vdD0nXKEaY2R/RWYe0CY3DPdMJScXU7eezjOD6CF5pr XLcNI39Gw6XSnVl+foX3oPS4yMcf62El1IX2EoOHsgSkzXe+Ki0iG6Xyl3COuGxg3rM6 1RenVa4I2+953BxSZfHNR/MoIgLsRfX5ADNBUwjWhHOQbo6g9QXuQrEkOTkiVDhEAyvp 1IE5hIIRDW0QwnqNhh9Y2N+DW7yVHBcM0bhLazuuNJAQrqBVJAEOP2b2GPoytZ3NiGL+ hAzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=WygdfWgc82JLORm6/ybR+mPW6gq6639PAYDpVjtVbrQ=; b=LxckL1ukINAWS98VwAcsvAokqVZR1t+wWII/aPYqj4nJIpRYetjoHLsI9Anc9IFBfU eJ357YtMjHpPEHhnDnbE59b5veyEwXjfRF+HTaoro0Lr022YdPKiYBERPDAlIr3ajd4v 2J21sPZ/N5V1POt364jY6dBAo0We1puxLheUARcn84JVg500higkyFxagT997rxZqIjX Wls8uM3wBtuHpL3GHsb3GPAvTvts3IQ5+FTkCfgBEpTwFFikBAMumpBvatjBOp8mYN/X 2vrq5LDgcEQw4vf5DRstd7LC0ujjtSzSnXfCisT4wjnthDeNVxVnXwX6bzkWqgLDaO6Q BkoA== X-Gm-Message-State: AGRZ1gJsO2p0ooKKVSHXXSXfQHAFkXsvkEjBq3Iv8SJG7ZXwUcX/jdlf NnsbO0LlOy7cu+lAxhCUSryulnZLw2XwhiQQ2IuqHA== X-Received: by 2002:a1f:7cca:: with SMTP id x193mr335348vkc.89.1541607002114; Wed, 07 Nov 2018 08:10:02 -0800 (PST) MIME-Version: 1.0 Received: by 2002:a67:f48d:0:0:0:0:0 with HTTP; Wed, 7 Nov 2018 08:10:01 -0800 (PST) In-Reply-To: <20181107160015.GI27423@dhcp22.suse.cz> References: <20181031150625.147369-1-dancol@google.com> <20181105132205.138695-1-dancol@google.com> <20181106130524.GC2453@dhcp22.suse.cz> <20181107160015.GI27423@dhcp22.suse.cz> From: Daniel Colascione Date: Wed, 7 Nov 2018 16:10:01 +0000 Message-ID: Subject: Re: [PATCH v2] Document /proc/pid PID reuse behavior To: Michal Hocko Cc: linux-kernel , rppt@linux.ibm.com, Tim Murray , Joel Fernandes , Suren Baghdasaryan , Jonathan Corbet , Andrew Morton , Roman Gushchin , Mike Rapoport , Vlastimil Babka , "Kirill A. Shutemov" , "Dennis Zhou (Facebook)" , Prashant Dhamdhere , "open list:DOCUMENTATION" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 7, 2018 at 4:00 PM, Michal Hocko wrote: > On Wed 07-11-18 15:48:20, Daniel Colascione wrote: >> On Tue, Nov 6, 2018 at 1:05 PM, Michal Hocko wrote: >> > otherwise anybody could simply DoS the system >> > by consuming all available pids. >> >> People can do that today using the instrument of terror widely known >> as fork(2). The only thing standing between fork(2) and a full process >> table is RLIMIT_NPROC. > > not really. What else, besides memory consumption and (as you mention below) cgroups? In practice, nobody uses RLIMIT_NPROC, so outside of various container-y namespaced setups, avoidance of system-DoS-through-PID-exhaustion isn't a pressing problem. If you really do care about pid space depletion then you > should use pid cgroup controller. Or that, sure. But since cgroups are optional, the problem with the core model remains. In general, if there's a problem X with the core system API, and you can mitigate X by using a cgroup, X is still a problem.