How can I stop my MacBook Pro from automatically sleeping when I lock the screen?
Solution 1:
Had the same problem in my Macbook(15") pro running 10.9.4.
I wanted my Mac to be locked while I was away (so configured hot corners) but at the same time did not want it to sleep (irrespective of whether it is connected to power or not) so that my wifi will be "ON" always for my jabber & mails. So here's what I did to prevent Mac from sleeping:
- Open Terminal
- Run
sudo pmset -a sleep 0
Explanation of the command:
pmset
command is to manipulate power management settings.-a
specifies that the setting applies for all conditions (power & battery)sleep
configure system sleep timer0
to disable
Check out man pmset
for more information.
Solution 2:
I found a solution that works for my needs: As it turns out, I should not lock the screen, but instead start the screensaver, and require the screensaver to immediately require a password.
I created a 'Start Screensaver' service with Automator, and then selected a keyboard shortcut for that service under Settings->Keyboard->Shortcuts->Services.
Solution 3:
The answer is in your post. Just uncheck "Wake for Wifi Access" in the System Preferences under Energy Saver, Power Adapter.
When it's checked, it means that your computer disconnects from the network when you're computer's not awake.