Start-DPMTapeDriveCleaning

Starts a job to clean a tape drive.

Syntax

Start-DPMTapeDriveCleaning [-TapeDrive] <Drive[]> [-JobStateChangedEventHandler <JobStateChangedEventHandler>]
 [-Confirm] [-WhatIf] [<CommonParameters>]

Description

The Start-DPMTapeDriveCleaning cmdlet starts a job to clean a tape drive.

Examples

Example 1: Clean a tape drive

PS C:\>$DpmLibrary = Get-DPMLibrary -DPMServerName "Contoso-DPMServer"
PS C:\> $DpmTapeDrive = Get-DPMTapeDrive -DPMLibrary $DPMLibrary
PS C:\> Start-DPMTapeDriveCleaning -TapeDrive $DpmTapeDrive

The first command uses the Get-DPMLibrary cmdlet to retrieve the library, and then stores it in the $DpmLibrary variable.

The second command uses the Get-DPMTapeDrive cmdlet to retrieve the tape drives in the library, and the stores the result in the $DpmTapeDrive variable.

The third command uses the Start-DPMTapeDriveCleaning cmdlet to clean the tape drive.

Parameters

-JobStateChangedEventHandler

Specifies an event handler for Job.StateChanged events. Use this parameter to build a graphical user interface based on cmdlets. Do not use this parameter in the System Center 2016 - Data Protection Manager (DPM) Management Shell.

Type:JobStateChangedEventHandler
Aliases:Handler
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-TapeDrive

Specifies an array of tape drives. This cmdlet cleans the drives that this parameter specifies.

Type:Drive[]
Required:True
Position:1
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-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
-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

Job