When transferring large files, there are times when I want to close the lid on my MacBook Pro laptop. It’s running on Mac OSX Mojave 10.14.5 and after several minutes of research, there’s not a built-in function to disable laptop sleep. Apple may have very good reasons for that.
But there are times when we can manage the risk of a closed lid with a running laptop.
Here’s the solution. Install and run the free utility InsomniaX- Keep your Mac awake the easy way. I downloaded it from download.cnet.com/InsomniaX/3000-2094_4-97713.html – but, it’s an older piece of software that was last updated 3 years ago, i.e. 2016.
However, there are 2 caveats:
- Security vulnerability discovered in 2017 – security fix patch at https://m4.rkw.io/blog/security-fix-for-insomniax-218.html
- the menu bar icon doesn’t change to indicate status on macOS newer than 10.12 – instructions below are from the official site https://github.com/semaja2/InsomniaX
Installing InsomniaX On OSX 10.12 and afterward
It seems that on systems with gatekeeper active, the kext module is not correctly loaded, if when the option Disable Lid Sleep is pressed the icon doesn’t change you are most likely affected. In that case use the following workaround [ed.note: Spotlight > Terminal]:
- Disable Gatekeeper:
sudo spctl --master-disable
- Launch InsomniaX and enable the option
disable lid sleep, fill out the administration password prompt if needed
- Rejoice, InsomniaX should be working and the kext should now be trusted by the system
- Re-Enable Gatekeeper:
- Either use:
sudo spctl --master-enable
- Or change the selector in Preferences->Security & Privacy->Generic back to AppStore & Signed Apps (Or even the more strict AppStore Only)
Thank You Andrew James
Thank you Andrew James for creating this very awesome utility!