A hotkey to kill a Linux process that eats all the memory

Step 1: Enable the SysRq button

Create a file /etc/sysctl.d/99-sysrq.conf with the following content:


To get it working you have to reboot, or run this command: sudo sysctl -w kernel.sysrq=1

Step 2: Try it

Now press ALT + SysRq + F and it should kill the process that uses most of the memory.