Erase-VBRTapeMedium

In this article

    Short Description

    Erases data from tape.

    Applies to

    Platform: VMware, Hyper-V

    Product Edition: Standard, Enterprise, Enterprise Plus, Veeam Universal License

    Syntax

    Erase-VBRTapeMedium -Medium <VBRTapeMedium[]> [-Long] [-Wait] [-WarningAction <ActionPreference>] [-WarningVariable <String>] [-WhatIf] [-Confirm] [<CommonParameters>]

    Detailed Description

    This cmdlet erases data from the selected tapes. The erased tapes are moved to the Free media pool.

    The cmdlet provides two scenarios for erasing options:

    • Short: only the tape data header is cleared. The tape becomes available for overwriting. Short erase is a quick procedure.
    • Long: all data is cleared from tape. This procedure requires more time.

    You cannot run erase for the following tapes:

    • Offline tapes
    • Tapes used by any jobs
    • Tapes with software or hardware protection.

    Parameters

    Parameter

    Description

    Required

    Position

    Accept
    Pipeline
    Input

    Accept
    Wildcard
    Characters

    Medium

    Specifies the array of tapes. The cmdlet will erase these tapes.

    Accepts VBRTapeMedium, GUID or string type.

    True

    Named

    True (ByValue,
    ByProperty
    Name)

    False

    Long

    Indicates that the cmdlet will perform the long (full) erase.

    Default: short erase.

    False

    Named

    False

    False

    Wait

    Indicates that the command waits for the erase process(es) to complete before accepting more input.

    False

    Named

    False

    False

    WhatIf

    Specifies whether the cmdlet writes a message that describes the effects of running the cmdlet without actually performing any action.

    False

    Named

    False

    False

    Confirm

    Specifies whether the cmdlet displays a prompt that asks if the user is sure that they want to continue.

    False

    Named

    False

    False

    <CommonParameters>

    This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About CommonParameters section of Microsoft Docs.

    Return Type

    VBRBackupSession

    Example 1

    This command runs short erase on the tape named "00170010".

    1. Run Get-VBRTapeMedium to get the tape and save it to the $tape variable.
    2. Run Erase-VBRTapeMedium with this variable.

    $tape = Get-VBRTapeMedium -Name "00170010"

    Erase-VBRTapeMedium -Medium $tape

    Example 2

    This command runs long erase on the tape named "00170010".

    1. Run Get-VBRTapeMedium to get the tape and save it to the $tape variable.
    2. Run Erase-VBRTapeMedium with this variable. Use the Long parameter.

    $tape = Get-VBRTapeMedium -Name "00170010"

    Erase-VBRTapeMedium -Medium $tape -Long

    Related Commands

    Get-VBRTapeMedium