New-DfsReplicationGroup
New-DfsReplicationGroup
Creates a replication group.
構文
Parameter Set: Default
New-DfsReplicationGroup [-GroupName] <String[]> [[-Description] <String> ] [[-DomainName] <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]
詳細説明
The New-DfsReplicationGroup cmdlet creates a replication group. A replication group is a set of servers, or members, that participate in the replication of one or more folders. A replicated folder is kept synchronized among the members of a replication group. This cmdlet cannot modify resource group bandwidth or schedules.
パラメーター
-Description<String>
Specifies a description for the replication group.
エイリアス |
なし |
必須? |
false |
位置は? |
2 |
既定値 |
なし |
パイプライン入力を許可する |
false |
ワイルドカード文字を許可する |
false |
-DomainName<String>
Specifies a NetBIOS or fully qualified domain name (FQDN) for the Active Directory domain that contains a replication group. If you do not specify this parameter, the cmdlet uses the current domain.
エイリアス |
なし |
必須? |
false |
位置は? |
101 |
既定値 |
[Current Domain] |
パイプライン入力を許可する |
True (ByPropertyName) |
ワイルドカード文字を許可する |
false |
-GroupName<String[]>
Specifies an array of names of replication groups.
エイリアス |
RG,RgName |
必須? |
true |
位置は? |
1 |
既定値 |
なし |
パイプライン入力を許可する |
True (ByValue, ByPropertyName) |
ワイルドカード文字を許可する |
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)。
入力
入力型は、コマンドレットにパイプできるオブジェクトの型です。
- Microsoft.DistributedFileSystemReplication.DfsReplicationGroup
出力
出力型は、コマンドレットによって生成されるオブジェクトの型です。
- Microsoft.DistributedFileSystemReplication.DfsReplicationGroup
例
Example 1: Create a replication group
This command creates a replication group named RG01.
PS C:\> New-DfsReplicationGroup -GroupName "RG01"
Example 2: Create a replication topology
This example creates a replication topology with an upstream server and two downstream servers.
The first command uses the New-DfsReplicationGroup cmdlet to create a replication group with the name Branch Office 1. The command pipes the output to the New-DfsReplicatedFolder cmdlet to create a replicated folder with the name Data Distribution 1. The command pipes the output to the Add-DfsrMember cmdlet to add the member servers named SRV01, SRV02, and SRV03. The command formats the output of the pipeline as a table.
The second command uses the Add-DfsrConnection cmdlet to add bidirectional connections between servers SRV01 and SRV02.
The third command uses the Add-DfsrConnection cmdlet to add bidirectional connections between servers SRV01 and SRV03.
The fourth command uses the Set-DfsrMembership cmdlet to set SRV01 as the primary member.
The fifth command uses the Set-DfsrMembership cmdlet to set membership for servers SRV02 and SRV03.
PS C:\> New-DfsReplicationGroup -GroupName "Branch Office 1" | New-DfsReplicatedFolder -FolderName "Data Distribution 1" | Add-DfsrMember -ComputerName SRV01, SRV02, SRV03 | Format-Table dnsname,groupname -auto -wrap
PS C:\> Add-DfsrConnection -GroupName "Branch Office 1" -SourceComputerName SRV01 -DestinationComputerName SRV02 | Format-Table *name -wrap -auto
PS C:\> Add-DfsrConnection -GroupName "Branch Office 1" -SourceComputerName SRV01 -DestinationComputerName SRV03 | Format-Table *name -wrap -auto
PS C:\> Set-DfsrMembership -GroupName "Branch Office 1" -FolderName "Data Distribution 1" -ContentPath c:\Rf01 -ComputerName SRV01 -PrimaryMember $True -StagingPathQuotaInMB 16384 -Force | Format-Table *name,*path,primary* -auto -wrap
PS C:\> Set-DfsrMembership -GroupName "Branch Office 1" -FolderName "Data Distribution 1" -ContentPath c:\Rf01 -ComputerName SRV02,SRV03 -StagingPathQuotaInMB 16384 -Force | Format-Table *name,*path,primary* -auto -wrap