Rename-DPMProtectionGroup
Rename-DPMProtectionGroup
Renames a protection group.
構文
Parameter Set: Default
Rename-DPMProtectionGroup [-ProtectionGroup] <ProtectionGroup> [-NewName] <String> [-PassThru] [-Confirm] [-WhatIf] [ <CommonParameters>]
詳細説明
The Rename-DPMProtectionGroup cmdlet renames a protection group on the System Center 2012 – Data Protection Manager (DPM) server. The process of renaming a protection group requires the following steps:
-- 1. Retrieve the protection group by using the Get-DPMProtectionGroup cmdlet.
-- 2. Make the protection group modifiable by using the Get-DPMModifiableProtectionGroup cmdlet.
-- 3. Rename the protection group by using the Rename-DPMProtectionGroup cmdlet.
-- 4. Save the changes by using the Set-DPMProtectionGroup cmdlet.
パラメーター
-NewName<String>
Specifies a new name for the protection group.
エイリアス |
none |
必須? |
true |
位置は? |
2 |
既定値 |
none |
パイプライン入力を許可する |
false |
ワイルドカード文字を許可する |
false |
-PassThru
Indicates that the cmdlet generates output. By default, this cmdlet does not generate output. You can use the PassThru parameter in order to use the cmdlet in a pipeline.
エイリアス |
none |
必須? |
false |
位置は? |
named |
既定値 |
none |
パイプライン入力を許可する |
false |
ワイルドカード文字を許可する |
false |
-ProtectionGroup<ProtectionGroup>
Specifies a ProtectionGroup object. To obtain a ProtectionGroup object, use the Get-DPMProtectionGroup cmdlet.
エイリアス |
none |
必須? |
true |
位置は? |
1 |
既定値 |
none |
パイプライン入力を許可する |
true (ByValue) |
ワイルドカード文字を許可する |
false |
-Confirm
コマンドレットを実行する前に、ユーザーに確認を求めます。
必須? |
false |
位置は? |
named |
既定値 |
false |
パイプライン入力を許可する |
false |
ワイルドカード文字を許可する |
false |
-WhatIf
コマンドレットを実行するとどのような結果になるかを表示します。コマンドレットは実行されません。
必須? |
false |
位置は? |
named |
既定値 |
false |
パイプライン入力を許可する |
false |
ワイルドカード文字を許可する |
false |
<CommonParameters>
このコマンドレットは次の共通パラメーターをサポートします。-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、-OutVariable.詳細については、以下を参照してください。 about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216)。
入力
入力型は、コマンドレットにパイプできるオブジェクトの型です。
出力
出力型は、コマンドレットによって生成されるオブジェクトの型です。
- ProtectionGroup
注
- For more information, type "
Get-Help Rename-DPMProtectionGroup -detailed
".
例
Example 1: Rename a protection group
This example renames a protection group on the DPM server.
The first command gets the protection group on the DPM server named DPMServer02, and stores the results in the $Pg variable.
The second command gets the protection group in a modifiable mode and stores the results in the $Mpg variable.
The third command renames the protection group stored in the $Mpg variable to ProtectGroup02.
The fourth command saves all the actions on the DPM server that you performed on the protection group stored in the $Mpg variable.
PS C:\> $Pg = Get-DPMProtectionGroup - DPMServerName "DPMServer02"
PS C:\> $Mpg = Get-DPMModifiableProtectionGroup -ProtectionGroup $Pg
PS C:\> Rename-DPMProtectionGroup -ProtectionGroup $Mpg -NewName "ProtectGroup02"
PS C:\> Set-DPMProtectionGroup $Mpg