This how-to will allow you to remap the SYSRQ key, that is absent in macbooks,
to any other key on the keyboard, allowing you to REISUB properly in the
moments of hard crashes.
Warning: To use this tip you MUST recompile your kernel.
You can use either the vanilla source or the ubuntu source.
Step 1. Edit the file include/linux/input.h
Search for the following line:
And replace the number 99 with the number of any other key.
#define KEY_SYSRQ 99
I personally prefer 126, the useless right apple key.
So my edited line looks like:
#define KEY_SYSRQ 126
Step 2. Enable Magic SYSRQ
Be sure to enable the Magic SYSRQ in:
[*] Kernel hacking -> Magic SysRq key
Step 3. Recompile the kernel and enjoy
Just recompile the kernel as usual.
Next time you boot, hold ALT + NEW_KEY and press REISUB slowly!