From: Steven Rostedt <rostedt@goodmis.org>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: "Peter Zijlstra" <peterz@infradead.org>,
LKML <linux-kernel@vger.kernel.org>,
"Ingo Molnar" <mingo@kernel.org>,
"Borislav Petkov" <bp@alien8.de>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Andrew Morton" <akpm@linux-foundation.org>,
"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Subject: Re: [PATCH v2] printk: Add kernel parameter to disable writes to /dev/kmsg
Date: Mon, 25 Apr 2016 15:35:26 -0400 [thread overview]
Message-ID: <20160425153526.284cb76a@gandalf.local.home> (raw)
In-Reply-To: <CA+55aFzKP4N0xSZGF4kkTcK7iOyAmOK+CR1B=DfD8=TsN0qnEA@mail.gmail.com>
On Mon, 25 Apr 2016 12:28:30 -0700
Linus Torvalds <torvalds@linux-foundation.org> wrote:
> On Mon, Apr 25, 2016 at 12:06 PM, Peter Zijlstra <peterz@infradead.org> wrote:
> >
> > Again, please default enable and use an easier name to toggle this.
> > Userspace flooding this with junk is really insane.
>
> I think it should be a tristate with "yes/no/ratelimit", and let's
> default to ratelimit.
Hmm, as this is currently decided on opening, it would be an
interesting task, and more complex. But I could look into it.
>
> And I also suspect that we would be better off not returning an error
> (which could make user space decide to break, either intentionally or
> just because some people think that "error handling is important"
> means that you should abort on all errors you don't recognize), but
> just silently drop the write. IOW, the "no" would just be a rather
> extreme form of rate-limiting, while "yes" would just be the other
> extreme.
>
Actually, systemd currently does the right thing when this errors on
opening. It finds another way to do logging. At least on my boxes that
I tested (Debian testing and Fedora 18). If it doesn't error out,
systemd may decided to continue to use this as its means for general
purpose logging, and now I lose out on the logging of userspace, as
everything that systemd does is silently dropped.
-- Steve
next prev parent reply other threads:[~2016-04-25 19:35 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-25 18:56 [PATCH v2] printk: Add kernel parameter to disable writes to /dev/kmsg Steven Rostedt
2016-04-25 19:06 ` Peter Zijlstra
2016-04-25 19:18 ` Greg Kroah-Hartman
2016-04-25 19:24 ` Peter Zijlstra
2016-04-25 19:44 ` Andrew Morton
2016-04-25 19:54 ` Greg Kroah-Hartman
2016-04-25 20:00 ` Steven Rostedt
2016-04-25 20:23 ` Linus Torvalds
2016-04-25 20:34 ` Steven Rostedt
2016-04-25 20:45 ` Linus Torvalds
2016-04-25 21:23 ` Steven Rostedt
2016-04-26 11:01 ` Borislav Petkov
2016-04-26 11:12 ` Peter Zijlstra
2016-04-25 19:30 ` Steven Rostedt
2016-04-25 19:28 ` Linus Torvalds
2016-04-25 19:34 ` Linus Torvalds
2016-04-25 19:35 ` Steven Rostedt [this message]
2016-04-25 19:44 ` Steven Rostedt
2016-04-26 5:36 ` Ingo Molnar
2016-04-26 10:43 ` Bjørn Mork
2016-04-26 11:09 ` Peter Zijlstra
2016-04-25 19:46 ` Andi Kleen
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=20160425153526.284cb76a@gandalf.local.home \
--to=rostedt@goodmis.org \
--cc=akpm@linux-foundation.org \
--cc=bp@alien8.de \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=torvalds@linux-foundation.org \
--cc=u.kleine-koenig@pengutronix.de \
/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;
as well as URLs for NNTP newsgroup(s).