Set-ProtectionType
Set-ProtectionType
Allows you to specify the protection type to be used with the protection group.
Syntax
Set-ProtectionType [-ProtectionGroup] <ProtectionGroup> [-LongTerm] [-PassThru <SwitchParameter>] [-ShortTerm <Nullable`1>] [<CommonParameters>]
Detailed Description
The Set-ProtectionType cmdlet allows you to specify the protection type to be used with the protection group.
The ShortTerm and LongTerm parameters can be used individually or in a combination to define the various protection types.
The various combinations are:
-ShortTerm Disk: Disk to Disk
-ShortTerm Tape: Disk to Tape
-LongTerm Tape: Disk to Tape (long-term)
-ShortTerm Disk -LongTerm: Disk to Disk to Tape
-ShortTerm Tape -LongTerm: Disk to Tape to Tape
Parameters
-ProtectionGroup
The name of a protection group.
Attributes
Name | Value |
---|---|
Required? |
true |
Accept wildcard characters? |
false |
Accept Pipeline Input? |
true (ByValue) |
Position? |
0 |
-LongTerm <Enum>
Indicates that the protection group is set to long-term tape protection. This parameter can take the values Tape, Online, and OnlineAndTape.
Attributes
Name | Value |
---|---|
Required? |
false |
Accept wildcard characters? |
false |
Accept Pipeline Input? |
false |
Position? |
named |
-PassThru
The -PassThru parameter can be used with many commands in DPM to return a related object in cases where there is no default output. Using the PassThru parameter allows such cmdlets to be part of a pipeline.
Attributes
Name | Value |
---|---|
Required? |
false |
Accept wildcard characters? |
false |
Accept Pipeline Input? |
false |
Position? |
named |
-ShortTerm
Indicates that the protection group will be on disk, on tape, or on neither, if nothing is specified.
Attributes
Name | Value |
---|---|
Required? |
false |
Accept wildcard characters? |
false |
Accept Pipeline Input? |
false |
Position? |
named |
-CommonParameter
This cmdlet supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction, WarningVariable, OutBuffer, and OutVariable. For more information, see about_CommonParameters.
Input and Return Types
The input type is the type of the objects that you can pipe to the cmdlet. The return type is the type of the objects that the cmdlet emits.
Notes
For more information, type "Get-Help Set-ProtectionType -detailed".
For technical information, type "Get-Help Set-ProtectionType -full".Additionally, any updated information about the cmdlet will be available at https://go.microsoft.com/fwlink/?LinkId=95130.
Examples
EXAMPLE 1
$pg = New-ProtectionGroup -DPMServerName TestingServer
Set-ProtectionType -ProtectionGroup $pg -ShortTerm disk
This command sets the protection type for the protection group to short-term on disk.
EXAMPLE 2
$pg = New-ProtectionGroup -DPMServerName TestingServer
Set-ProtectionType -ProtectionGroup $pg -ShortTerm disk –LongTerm Tape
This command sets the protection type for the protection group to disk to disk to tape.