Windows 8 PowerCfg -Energy

PowerCfg -Energy for Troubleshooting Sleep ProblemsPowercfg -Energy Windows 8

Windows 8 has built-in utility called PowerCfg; when troubleshooting sleep problems, I find its little-known switch -Energy invaluable.

Topics for Windows 8 PowerCfg -Energy


Guy’s Rule for Laptops Notebooks and Tablets

Every mobile computer exhibits at least one of these Power Management issues.

  • Won’t awaken up from sleep or hibernation.
  • Suddenly wakes up for no apparent reason.
  • Refuses your attempt to set: Sleep, Hibernate or Standby.
  • Battery life does not come close to manufacturer's claim.

Using PowerShell to Run PowerCfg -Energy

The old-fashioned way was to run built-in Windows utilities is by launching a 'DOS box' with cmd.exe; the modern way is execute all command-line programs through PowerShell.  PowerCfg with PowerShell seems particularly apt.

Here is an example:

PS C:\WINDOWS\system32> PowerCfg -Energy
Enabling tracing for 60 seconds…
Observing system behavior…
Analyzing trace data…
Analysis complete.

Energy efficiency problems were found.

8 Errors
47 Warnings
11 Informational

Note 1: When you run the command, scroll down to the bottom, observe a note saying:
See C:\WINDOWS\system32\energy-report.html for more details.

Note 2: The energy-report.html file is created in the current directory, and not necessarily in the \windows\system32 folder.

Guy Recommends: SolarWinds Free Wake-On-LAN UtilitySolarwinds Wake-On-LAN

Encouraging computers to sleep when they’re not in use is a great idea – until you are away from your desk and need a file on that remote sleeping machine!

WOL also has business uses for example, rousing machines so that they can have update patches applied.  My real reason for recommending you download this free tool is because it’s so much fun sending those ‘Magic Packets’. Give WOL a try – it’s free.

Download your free copy of SolarWinds Wake-On-LAN

Examining the Energy-report.html

Here are more details about sleep from the resultant energy-report.html.

Platform Power Management Capabilities:

Supported Sleep States
Sleep states allow the computer to enter low-power modes after a period of inactivity. The S3 sleep state is the default sleep, and only consumes only enough power to preserve memory contents and allow the computer to resume working quickly.

S1 Sleep Supported true
S2 Sleep Supported false
S3 Sleep Supported true (Sleep)
S4 Sleep Supported true (Called Hibernate)

Very few platforms support the S1 or S2 Sleep states.

PowerCfg -Energy Analysis Results

The energy-report.html is even color coded.  Here is an example of a service that is preventing your computer from sleeping.

System Availability Requests:System Required Request
The service has made a request to prevent the system from automatically entering sleep.
Requesting Service defragsvc (Defrag)

This warning could explain why the battery life is shorter than advertised.

Power Policy:Disk timeout is long (Plugged In)
The disk is configured to turn off after longer than 30 minutes.
Timeout (seconds) 1860

Note 3: When working with PowerCfg I like to have the Device Manager open so that I can check the 'Power Management' tab of the mouse, keyboard and other devices that could bring the computer out of its slumber.

Guy Recommends:  A Free Trial of the Network Performance Monitor (NPM)Review of Orion NPM v11.5 v11.5

SolarWinds’ Orion performance monitor will help you discover what’s happening on your network.  This utility will also guide you through troubleshooting; the dashboard will indicate whether the root cause is a broken link, faulty equipment or resource overload.

What I like best is the way NPM suggests solutions to network problems.  Its also has the ability to monitor the health of individual VMware virtual machines.  If you are interested in troubleshooting, and creating network maps, then I recommend that you try NPM now.

Download a free trial of Solarwinds’ Network Performance Monitor

Windows 8 PowerCfgSleep Policies Windows 8 Benefits

  • I find PowerCfg quicker to use troubleshooting than the Control Panel’s Power Management GUI.
  • This utility can also be used in Windows 7, but not Server 2008.
  • The report reveals vital information on which devices are supposed to wake the computer.
  • PowerCfg helps you to understand the inter-relationship between the sleep components.
  • Experiment with PowerCfg led me to investigate group policies that were controlling sleep settings.
    Computer Configuration\System\Power Management.  (See screenshot right)

Researching More Switches with PowerCfg /?

For troubleshooting power-related problems there are several other useful switches to see the full list try: PowerCfg /?

/LASTWAKE Reports what woke the system from the last sleep.
/WAKETIMERS Enumerates active wake timers.
/BATTERYREPORT Generates a report of battery usage.

Note 4: As with many command-line utilities you could use the /forward slash instead of the -dash.  Incidentally, the help file shows the /, where as most people perfer the -dash as used with PowerShell's parameters.

Refining PowerCfg -Energy

Research other switches reveals that -Energy itself has modifies such as -Trace and -XML (creates energy-report.xml instead of .html).  There is also a -Duration to adjust the time it takes to analyze your computer's settings.

Example of a Battery Report

Battery:Battery Information
Battery ID Sony Corp.
Manufacturer Sony Corp.
Serial Number
Chemistry LiOn
Long Term 1
Design Capacity 57720
Last Full Charge 57720

Sleep Mode v Hibernate
When you close a laptop's lid the operating system cuts the power to all unneeded parts of the machine, thus conserving power.  In this sleeping mode, there is a trickle of power to the RAM so that it can restart the disk and monitor when a user presses a key.  (S3 mode in BIOS)

In the case of hibernation, the disks have to spin-up and the operating system must read the hiberfil.sys file, hence you can detect an appreciable delay before the machine is ready to accept user input.  (S4 mode in BIOS)

Solarwinds Config GeneratorGuy Recommends: The Free Config Generator

SolarWinds’ Config Generator is a free tool, which puts you in charge of controlling changes to network routers and other SNMP devices.  Boost your network performance by activating network device features you’ve already paid for.

Guy says that for newbies the biggest benefit of this free tool is that it will provide the impetus for you to learn more about configuring the SNMP service with its ‘Traps’ and ‘Communities’. Try Config Generator now – it’s free!

Download your free copy of Config Generator

Troubleshooting Sleep Problems with PowerCfg

Here are ideas to troubleshoot common sleep or premature awakening problems using PowerCfg and its switches.

Problem 1: Access Denied

The most common problem is access denied despite being and administrator, and using 'Run as Administrator'.

Solution 1a: Create another Administrator, logon as that account.

Solution 1b: Run scannow /sfc the PowerCfg.exe maybe corrupted.

Problem 2: Windows 8 Won't Sleep

PowerCfg /Requests

This /Requests switch will display what's blocking sleep.  Once you have identified the component try:

Solution 2:

PowerCfg /Requestsoverride Driver "Legacy xyz" System

Problem 3: Computer Wakes Randomly

Solution 3 and 3a:

PowerCfg /Lastwake

# Also remove the # and try:
# PowerCfg /DEVICEQUERY wake_armed

Problem 4: Could not open the NT Kernel Logger

I once had a message saying that PowerCfg could not run, because the logger was already running.

Solution 4:  Close Performance Monitor.

See more on Windows 8 Sleep Mode »

Summary of Windows 8 PowerCfg -Energy

Windows 8's PowerCfg has a useful switch called -Energy.  This technique is invaluable for troubleshooting sleep problems, particularly on Windows laptop or notebook or tablet mobile computers.

If you like this page then please share it with your friends


Microsoft Windows 8 Troubleshooting Topics

Windows 8 Overview  • Win 8 Event Viewer  • Windows 8 Shutdown  • Windows 8 Join Domain

Windows 8 Performance Monitor  • Windows 8 PowerCfg -Energy  • Windows 8 Sleep Problems

Windows 8 Troubleshooting  • Windows 8 Sound Problems  • Win 8 Server Admin Tools  • Tookit