Remove-SCVMMManagedComputer

Removes a computer from VMM management.

Syntax

Remove-SCVMMManagedComputer
      [-VMMManagedComputer] <VMMManagedComputer>
      -Credential <VMMCredential>
      [-RunAsynchronously]
      [-PROTipID <Guid>]
      [-JobVariable <String>]
      [<CommonParameters>]

Description

The Remove-SCVMMManagedComputer cmdlet removes computer objects from Virtual Machine Manager (VMM) management.

Examples

Example 1: Remove a managed computer object

PS C:\> $RunAsAccount = Get-SCRunAsAccount -Name "RunAsAcct01"
PS C:\> Get-SCVMMManagedComputer -ComputerName "SPF.Contoso.com" | Remove-SCVMMManagedComputer -Credential $RunAsAccount

The first command gets the Run as account object named RunAsAcct01 and stores the object in the $RunAsAccount variable.

The second command gets the managed computer object named SPF.Contoso.com and uses the pipeline operator to pass the object to Remove-SCVMMManagedComputer, which removes the computer from VMM management.

Parameters

-Credential

Specifies a credential object or, for some cmdlets, a Run As account object that contains the user name and password of an account that has permission to perform this action. Or, in the case of Restart-SCJob, has permission to complete a restarted task.

For more information about the PSCredential object, type Get-Help Get-Credential.

For more information about Run As accounts, type Get-Help New-SCRunAsAccount.

Type:VMMCredential
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-JobVariable

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

Type:String
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-VMMManagedComputer

Specifies a computer object that is managed by VMM.

Type:VMMManagedComputer
Position:0
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False