Remove-WssBackupConfiguration

Removes a file specification from a backup volume.

Syntax

Remove-WssBackupConfiguration
      [-Volume] <BackupVolume>
      [-Configuration] <BackupFileSpec>
      [<CommonParameters>]

Description

The Remove-WssBackupConfiguration cmdlet removes a file specification from a backup volume. When you remove a file specification from a backup volume, the files and folders in the file specification are no longer backed up with the backup volume.

Examples

Example 1: Remove a file specification from a backup volume

PS C:\>$ContosoBUVolume110 = Get-WssBackupVolume -AllVolumes
PS C:\> $ContosoBUFilespec05 = Get-WssBackupConfiguration -Volume $ContosoBUVolume110[0]
PS C:\> Remove-WssBackupConfiguration -Configuration $ContosoBUFilespec05[1]

This command removes the backup file specification from a backup volume.

The first command gets the backup volumes from the server and stores them in the $ContosoBUVolume110 variable.

The second command gets the backup file specification from the first item (located in position 0) in $ContosoBUVolume110 and stores the backup file specification in the $ContosoBUFilespec05 variable.

The third command removes the backup file specification from the second item (located in position 1) in $ContosoBUFilespec05.

Parameters

-Configuration

Specifies the backup file specification to remove from the volume.

Type:BackupFileSpec
Aliases:Config
Position:1
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Volume

Specifies the volume from which to remove the file specification.

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

Inputs

Microsoft.WindowsServerSolutions.DataProtection.ServerBackup.ObjectModel.BackupVolume

Outputs

Microsoft.WindowsServerSolutions.DataProtection.ServerBackup.ObjectModel.BackupFileSpec

This cmdlet generates an object that indicates whether to include or exclude files or folders in the server backup.