/proc/sysrq-trigger what can be done with this file?
# Restart your computer now (reboots the kernel without first unmounting file systems or syncing disks attached to the system)
echo "B" >/proc/sysrq-trigger
# Turn off the computer immediately (shuts off the system)
echo "O" >/proc/sysrq-trigger
# Export memory allocation information (can be viewed with/var/log/message) (Outputs memories Statistics to the console)
echo "M" >/proc/sysrq-trigger
# Export Current CPU register information and flag bit information (Outputs all flags and registers to the console)
echo "P" >/proc/sysrq-trigger
# Export Thread state information (Outputs a list of processes to the console)
echo "T" >/proc/sysrq-trigger
# deliberately let the system crash (crashes the systems without first unmounting file systems or syncing disks attached to the system)
echo "C" >/proc/sysrq-trigger
# immediately re-mount all file systems (attempts to sync disks attached to the system)
echo "S" >/proc/sysrq-trigger
# immediately re-mount all the file systems as read-only (attempts to unmount and remount all files system as Read-only)
echo "U" >/proc/sysrq-trigger
Hehe, there are also two, similar to the Force logoff function
e
-kills all processes except init
using SIGTERM-kills all
i
processes except init
using S Igkill
Features of/proc/sysrq-trigger files under Linux