public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>,
	Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com>
Cc: LKML <linux-kernel@vger.kernel.org>, Greg KH <gregkh@suse.de>
Subject: /proc/sys/kernel/pty/nr broken, possibly since 2.6.28
Date: Thu, 05 Nov 2009 15:51:15 -0800	[thread overview]
Message-ID: <4AF364F3.4070300@zytor.com> (raw)

I just noticed that /proc/sys/kernel/pty/nr is broken, and the most
likely culprit seems to be the series of checkins that include 8b0a88d5
and bf970ee4, during the 2.6.28 merge window.  This is thus a
regression.  I haven't verified that the bug really goes that far back
-- I should do a bisection -- but it is at least present in 2.6.30.9 and
2.6.32-rc6.

The symptom is that /proc/sys/kernel/pty/nr is properly increased, but
never decreased when a pty gets dropped.  It is in fact rather trivial
to escalate /proc/sys/kernel/pty/nr far above /proc/sys/kernel/pty/max.

As far as I read this series, the indent was to have this accounting
handled in pty_unix98_remove(), however, it would appear that that
function never gets called.  I'm wondering if this may be a symptom of a
bigger problem as well.

	-hpa

             reply	other threads:[~2009-11-05 23:51 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-05 23:51 H. Peter Anvin [this message]
2009-11-06  1:04 ` /proc/sys/kernel/pty/nr broken, possibly since 2.6.28 H. Peter Anvin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4AF364F3.4070300@zytor.com \
    --to=hpa@zytor.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=gregkh@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sukadev@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox