21

How can I find out why my laptop or desktop won't automatically go to sleep

Omar Shahine
  • 2,597

6 Answers6

21

I believe that Windows 7 is the only version of Windows which can tell you what devices are preventing the machine from sleeping. Windows 7 and Vista can tell you what devices are armed to wake the device from sleep.

There is a tool called powercfg which can do this. New to Windows 7 is the ability to see what is armed.

Windows 7

  1. Open an elevated command prompt
  2. Type powercfg /requests

You will see a list of items preventing the machine from entering sleep.

Omar Shahine
  • 2,597
14

Vista also has powercfg.exe, which can tell you which devices are armed to wake the system from sleep:

powercfg -devicequery wake_armed

as well as which device last woke the machine from sleep:

powercfg -lastwake

Sounds like Windows 7 got some new features though.

Kevin Dente
  • 1,053
1

It took me a while but this solved it for me. Create a batch file with the following content:

powercfg -requestsoverride PROCESS chrome.exe awaymode display system
net stop "Windows Update" & net start "Windows Update"

(the second part of the net command is not mandatory because the service restarts anyway)

... then create a Windows task to execute the batch file every 30 minutes (don't forget to add execute in privileged mode.

Sorin
  • 11
  • 1
1

In case it helps anyone, here is what it was in my case.

My computer was reporting (via this script) that user inputs were received more than once a second, all the time.

After disabling both the keyboard and the mouse with no change, I removed all usb devices and connected them one by one while checking for idle.

The culprit turned out to be a WingMan joystick, that was powered off but still connected to the usb port. As soon as I disconnected it the computer was idling properly.

1

you can also run powercfg -energy from an elevated cmd. this will monitor your PC for 60secs during which you should continue using it normally.

A report is generated at the end. Looking at Errors in this report should give you a clue as to what is preventing your PC from going to sleep.

one of the most common issues is Media sharing. This shows up as \Filesystem\srvnet in the report. You will need to turn off media sharing to get rid of this issue.

If its something different, do post any questions you have. thanks

AtharvaI
  • 153
0

There's also a Power-Troubleshooter source within Vista's Event Viewer in the Application event log with related information such as Wake Source.