Tom Gall (firstname.lastname@example.org), Staff Software Engineer, IBM Linux Technology Center
01 Apr 2000
If you are working with the development kernel or device drivers, or running code that could cause your machine to kernel panic, you'll want this tip.
This tip works on Linux with x86, PowerPC, or SPARC processors, and you need to be at least in the 2.2.x or above series of kernels.
If your machine should panic, or seem suddenly to turn into a molten heap of parts, you can, via a key combination, sync your file system and remount your file systems to read-only. On the following reboot, you'll avoid a potentially lengthy fsck.
The key combinations are a little different from platform to platform:
|PowerPC||ALT-Print Screen-[command key]|
The command keys are as follows:
|s||Attempts to sync all mounted file systems|
|u||Attempts to remount all mounted file systems to read-only |
|b||Attempts to immediately reboot your system|
(This is effectively like hitting the reset switch or
power button on your box; processes will not
be given the chance to shut down.)
|p||Prints the current set of registers and flags to the console|
|t||Prints the list of current tasks and related information to the console |
|e||Sends a SIGTERM to all processes, with the exception of init|
|i||Sends a SIGKILL to all processes, with the exception of init|
|l||Sends a SIGKILL to all processes|
For more information, check /usr/src/linux/Documentation/sysrq.txt. Other key combinations are available.
About the author
Tom Gall works for the IBM Linux Technology Center. When he's not hacking on Linux, he's either spending time with his fiancee, Jen, herding cats, or up to something with the Rochester Civic Theatre. Tom first got into computing at the age of 12 back in 1981 when he bought a VIC 20 on his paper-boy salary. He can be reached at email@example.com.
Rate this page