commands

^

Get-DbaPowerPlan

Author Chrissy LeMaire (@cl), netnerds.net
Availability Windows only

 

Synopsis

Gets the Power Plan settings for compliance with best practices, which recommend High Performance for SQL Server.

Description

Gets the Power Plan settings on a computer against best practices recommendations.

Syntax

Get-DbaPowerPlan
    [-ComputerName] <DbaInstanceParameter[]>
    [[-Credential] <PSCredential>]
    [-EnableException]
    [<CommonParameters>]

 

Examples

 

Example: 1
PS C:\> Get-DbaPowerPlan -ComputerName sql2017

Gets the Power Plan settings for sql2017

Example: 2
PS C:\> Get-DbaPowerPlan -ComputerName sql2017 -Credential ad\admin

Gets the Power Plan settings for sql2017 using an alternative credential

Required Parameters

-ComputerName

The server(s) to check Power Plan settings on.

Alias
Required True
Pipeline true (ByValue)
Default Value

Optional Parameters

-Credential

Specifies a PSCredential object to use in authenticating to the server(s), instead of the current user account.

Alias
Required False
Pipeline false
Default Value
-EnableException

By default, when something goes wrong we try to catch it, interpret it and give you a friendly warning message. This avoids overwhelming you with "sea of red" exceptions, but is inconvenient because it basically disables advanced scripting. Using this switch turns this "nice by default" feature off and enables you to catch exceptions with your own try/catch.

Alias
Required False
Pipeline false
Default Value False

 

Want to see the source code for this command? Check out Get-DbaPowerPlan on GitHub.
Want to see the Bill Of Health for this command? Check out Get-DbaPowerPlan.