summaryrefslogtreecommitdiff
path: root/Documentation/admin-guide/sysrq.rst
AgeCommit message (Collapse)AuthorFilesLines
2024-04-11tty/sysrq: Replay kernel log messages on consoles via sysrqSreenath Vijayan1-0/+9
When terminal is unresponsive, one cannot use dmesg to view the printk ring buffer messages. Also, syslog services may be disabled, especially on embedded systems, to check the messages after a reboot. In this scenario, replay the messages in printk ring buffer on consoles via sysrq by pressing sysrq+R. The console loglevel will determine which all kernel log messages are displayed. The messages will be displayed only when console_trylock() succeeds. Users could repeat the sysrq key when it fails. If the owner of console subsystem lock is stuck, repeating the key won't work. Suggested-by: Petr Mladek <pmladek@suse.com> Signed-off-by: Shimoyashiki Taichi <taichi.shimoyashiki@sony.com> Reviewed-by: John Ogness <john.ogness@linutronix.de> Signed-off-by: Sreenath Vijayan <sreenath.vijayan@sony.com> Link: https://lore.kernel.org/r/cc3b9b1aae60a236c6aed1dc7b0ffa2c7cd1f183.1710220326.git.sreenath.vijayan@sony.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-11-25/proc/sysrq-trigger: accept multiple keys at onceTomas Mudrunka1-1/+10
This way we can do: `echo _reisub > /proc/sysrq-trigger` Instead of: `for i in r e i s u b; do echo "$i" > /proc/sysrq-trigger; done;` This can be very useful when trying to execute sysrq combo remotely or from userspace. When sending keys in multiple separate writes, userspace (eg. bash or ssh) can be killed before whole combo is completed. Therefore putting all keys in single write is more robust approach. Signed-off-by: Tomas Mudrunka <tomas.mudrunka@gmail.com> Reviewed-by: Jiri Slaby <jirislaby@kernel.org> Link: https://lore.kernel.org/r/20231120111451.527952-1-tomas.mudrunka@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-02-02Documentation: admin-guide: correct spellingRandy Dunlap1-1/+1
Correct spelling problems for Documentation/admin-guide/ as reported by codespell. Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Reviewed-by: Mukesh Ojha <quic_mojha@quicinc.com> Cc: Tejun Heo <tj@kernel.org> Cc: Zefan Li <lizefan.x@bytedance.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: cgroups@vger.kernel.org Cc: Alasdair Kergon <agk@redhat.com> Cc: Mike Snitzer <snitzer@kernel.org> Cc: dm-devel@redhat.com Cc: Mauro Carvalho Chehab <mchehab@kernel.org> Cc: linux-media@vger.kernel.org Cc: linux-mm@kvack.org Link: https://lore.kernel.org/r/20230129231053.20863-2-rdunlap@infradead.org Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2021-07-15Documentation: sysrq: convert to third personCengiz Can1-5/+7
Two parts of the sysrq documentation have sentences written from a first person's point of view. Documentation is generally written from a third person's view in a formal way. Convert those senteces to be less personal and generic. Signed-off-by: Cengiz Can <cengiz@kernel.wtf> Link: https://lore.kernel.org/r/20210629141508.52229-1-cengiz@kernel.wtf Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2021-03-15Documentation: sysrq: update description about sysrq crashGao Xiang1-2/+2
After commit 8341f2f222d7 ("sysrq: Use panic() to force a crash"), a crash was not generated by dereferencing a NULL pointer anymore. Let's update documentation as well to make it less misleading. Signed-off-by: Gao Xiang <hsiangkao@redhat.com> Cc: Matthias Kaehlcke <mka@chromium.org> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Zefan Li <lizefan.x@bytedance.com> Link: https://lore.kernel.org/r/20210309191550.3955601-1-hsiangkao@redhat.com Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2020-10-02tty/sysrq: Extend the sysrq_key_table to cover capital lettersAndrzej Pietrasiewicz1-0/+2
All slots in sysrq_key_table[] are either used, reserved or at least commented with their intended use. This patch adds capital letter versions available, which means adding 26 more entries. For already existing SysRq operations the user presses Alt-SysRq-<key>, and for the newly added ones Alt-Shift-SysRq-<key>. Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@collabora.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: https://lore.kernel.org/r/20200818112825.6445-2-andrzej.p@collabora.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-05-15tty/sysrq: constify the sysrq APIEmil Velikov1-5/+5
The user is not supposed to thinker with the underlying sysrq_key_op. Make that explicit by adding a handful of const notations. Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Jiri Slaby <jslaby@suse.com> Cc: linux-kernel@vger.kernel.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Link: https://lore.kernel.org/r/20200513214351.2138580-2-emil.l.velikov@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-07Documentation: sysrq: fix RST formattingAlyssa Ross1-9/+11
"On x86" and "On SPARC" are now definition list terms, like "On PowerPC", "On other", and "On all". The Credits list is now a bulleted list, like lots of Credits lists in other files. This prevents the list from becoming a single long, unpunctuated sentence in the generated documentation. I also did a couple of other tiny readability improvements to the "How do I use the magic SysRq key?" section while I was there. Signed-off-by: Alyssa Ross <hi@alyssa.is> Link: https://lore.kernel.org/r/20200403170701.10852-1-hi@alyssa.is Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2019-09-06Documentation: sysrq: don't recommend 'S' 'U' before 'B'Adam Borowski1-11/+9
This advice is obsolete and slightly harmful for filesystems from this millenium: any modern filesystem can handle unexpected crashes without requiring fsck -- and on the other hand, trying to write to the disk when the kernel is in a bad state risks introducing corruption. For ext2, any unsafe shutdown meant widespread breakage, but it's no longer a reasonable filesystem for any non-special use. Signed-off-by: Adam Borowski <kilobyte@angband.pl> Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2017-03-14Documentation: admin-guide: fix path to input key definitionsMartin Kepplinger1-1/+2
The UAPI header split failed to update the documentation here; fix things accordingly. Signed-off-by: Martin Kepplinger <martink@posteo.de> Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2016-10-24docs-rst: create an user's manual bookMauro Carvalho Chehab1-0/+289
Place README, REPORTING-BUGS, SecurityBugs and kernel-parameters on an user's manual book. As we'll be numbering the user's manual, remove the manual numbering from SecurityBugs. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>