Clear-SCPowerOptimizationSchedule

Deletes a power optimization time range from a dynamic optimization configuration.

Syntax

Clear-SCPowerOptimizationSchedule [-Confirm] -DynamicOptimizationConfiguration <HostGroupDOSettings>
 [-JobVariable <String>] [-PROTipID <Guid>] [-RunAsynchronously] [-VMMServer <ServerConnection>] [-WhatIf]
 [<CommonParameters>]

Description

The Clear-SCPowerOptimizationSchedule cmdlet deletes power optimization time ranges from the power optimization schedule configured for a dynamic optimization configuration.

Examples

Example 1: Remove all power opmization time ranges associated with a dynamic optimization configuration

PS C:\> $HostGroup = Get-SCVMHostGroup "HostGroup01"
PS C:\> $DOConfig = Get-SCDynamicOptimizationConfiguration -VMHostGroup $HostGroup 
PS C:\> Clear-SCPowerOptimizationSchedule -DynamicOptimizationConfiguration $DOConfig

The first command gets the host group object named HostGroup01 and stores the object in the $HostGroup variable.

The second command gets the dynamic optimization configuration object for the host group stored in $HostGroup and stores the object in the $DOConfig variable.

The last command clears all time ranges in the power optimization schedule for the dynamic optimization configuration stored in $DOConfig.

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False
-DynamicOptimizationConfiguration

Specifies a dynamic optimization configuration object.

Type:HostGroupDOSettings
Required:True
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-JobVariable

Specifies that job progress is tracked and stored in the variable named by this parameter.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PROTipID

Specifies the ID of the Performance and Resource Optimization tip (PRO tip) that triggered this action. This parameter lets you audit PRO tips.

Type:Guid
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RunAsynchronously

Indicates that the job runs asynchronously so that control returns to the command shell immediately.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VMMServer

Specifies a Virtual Machine Manager (VMM) server object.

Type:ServerConnection
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False

Outputs

PowerOptimizationSchedule

This cmdlet returns a **PowerOptimizationSchedule** object.