SysRq

From Noah.org
Revision as of 12:59, 26 November 2012 by Root (talk | contribs)
Jump to navigationJump to search


Official SysRq Documentation

There is a bit of a trick to using the Magic SysRq key sequence. The trick is to hold the Alt key during the entire process. Press Alt first; hold it; press the SysRq button; then press whatever key you want. Finally, you can release the Alt key.

Output will not go to an X terminal. It will be printed on the console. Press Ctrl-Alt-F1 to switch view to the console.

One some keyboards (especially Microsoft), you may find a key called F Lock. This is a stupid key. It's almost like they added a new CapsLock key except that there is no indicator to show that it is turned on. Often you need to press this once before you start. If you switch to a text console you may find that you cannot switch back to the X Window platform. Press F Lock once again to restore the function of the function keys.

SysRq output

The output of SysRq is logged to the console. If you have debugging set very low then you might not see anything. You can run `dmesg` to see the output or you can increase log visibility by using a SysRq command. Press the following keys to set log visibility to a high level

Alt SysRq 9

Send SysRq without keyboard

You can bypass the keyboard magic keys simply be writing the command code that want to execute to the following file:

echo h > /proc/sysrq-trigger

Enable / Disable SysRq

Enable, write a 1. To disable, write 0:

echo 1 > /proc/sys/kernel/sysrq

Freezing and unfreezing

Notes

Note: Sometimes called SysReq and Sys Request.