Remove-SCServiceConfiguration

Deletes a service configuration object from the VMM library.

Description

The Remove-SCServiceConfiguration deletes one or more service configuration objects from the System Center Virtual Machine Manager library.

For more information about Remove-SCServiceConfiguration, type: "Get-Help Remove-SCServiceConfiguration -online".

Parameters

ServiceConfiguration

Required? true
Accept Pipeline Input? true (ByValue)
Position? 0
Specifies a service configuration object.

Confirm

Required? false
Accept Pipeline Input? false
Position? named
Prompts for confirmation before running the command.

JobVariable

Required? false
Accept Pipeline Input? false
Position? named
Specifies that job progress is tracked and stored in the variable named by this parameter. 

PROTipID

Required? false
Accept Pipeline Input? false
Position? named
Specifies the ID of the PRO tip that triggered this action. This allows for auditing of PRO tips.

RunAsynchronously

Required? false
Accept Pipeline Input? false
Position? named
Indicates that the job runs asynchronously so that control returns to the command shell immediately. 

VMMServer

Required? false
Accept Pipeline Input? false
Position? named
Specifies a VMM server object.

Examples

1: Remove a specific service configuration object from the library.
PS C:\> $SvcConfig = Get-SCServiceConfiguration -VMMServer "VMMServer01.Contoso.com" -Name "Service01"
PS C:\> Remove-SCServiceConfiguration -ServiceConfiguration $SvcConfig -Confirm

The first command gets the service configuration object named Service01 and stores the object in the $SvcConfig variable.

The second command removes the service configuration object stored in $SvcConfig from the VMM database and deletes the corresponding service configuration object and all other associated objects in the library. A confirmation prompt is displayed before the the service configuration object is removed.
2. Remove all service configuration objects
PS C:\> $SvcConfigs = Get-SCServiceConfiguration -VMMServer "VMMServer01.Contoso.com"
PS C:\> $SvcConfigs | Remove-SCServiceConfiguration -Confirm
The first command gets all service configuration objects on VMMServer01 and stores the objects in the $SvcConfigs variable.

The second command removes all the service configuration objects stored in $SvcConfigs and deletes all other associated objects in the library. A confirmation prompt is displayed before the the service configuration objects are removed.

See Also