lkml.org 
[lkml]   [2016]   [Apr]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: printk: Add kernel parameter to disable writes to /dev/kmsg
On Mon 2016-04-25 13:06:29, Steven Rostedt wrote:
> Over the weekend my server was acting funny. The display wasn't working
> well, and I assumed that a driver was going bad. I went to look at the
> kernel dmesg, but the buffer only had the following over and over:
>
> [226062.401405] systemd-logind[3511]: Removed session 4168.
> [226063.381051] systemd-logind[3511]: Removed session 4169.

systemd has root. I'm not sure additional parameter to fight it is
good idea. What's next? systemd evolves a way to override kernel
parameters? :-)

> I simply propose a way to let us kernel developers keep user space from
> interfering, by adding a new kernel command line parameter that will
> disable writing to /dev/kmsg. Any attempt to open the file in write
> mode will return a -EPERM error.

chmod 400 /dev/kmsg? With udev, it should be possible to make it persistent...

Pavel

--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

\
 
 \ /
  Last update: 2016-04-26 21:01    [W:0.066 / U:0.380 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site