Quantcast
Channel: File Services and Storage forum
Viewing all articles
Browse latest Browse all 10672

DFSR Error creating folder membership

$
0
0

Hi all,

I'm getting a really strange error when running the following sample code in powershell to add a replicated folder to an already existing replication group.

Both servers are virtual and running Server 2012 r2.

$GroupName = "FILES_SA"
$FolderName = "DEPT_Share"
$PrimaryComputer = "PrimaryServer.ad.domain.com"
$SecondaryComputer = "SecondaryServer.ad.domain.com"
$ContentPath = "M:\DEPT\SHARE"

New-DfsReplicatedFolder -GroupName $GroupName -FolderName $FolderName
Set-DfsrMembership -GroupName $GroupName -FolderName $FolderName -ComputerName $PrimaryComputer -ContentPath $ContentPath -PrimaryMember $true -Force
Set-DfsrMembership -GroupName $GroupName -FolderName $FolderName -ComputerName $SecondaryComputer -ContentPath $ContentPath -PrimaryMember $false -Force

When it gets to the last command I get the following error:

Set-DfsrMembership : Could not edit the DFSR membership with domain: ; replication group: "FILES_SA"; replicated folder: "DEPT_Share"; computer: 
SecondaryServer.ad.domain.com; GUID: None specified. The filename, directory name, or volume label syntax is incorrect
At C:\Users\username-admin\Desktop\Untitled2.ps1:9 char:1+ Set-DfsrMembership -GroupName $GroupName -FolderName $FolderName -ComputerName $ ...+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~+ CategoryInfo          : NotSpecified: (DFSR membership...None specified.:String) [Set-DfsrMembership], DfsrException+ FullyQualifiedErrorId : Set-DfsrMembership.OMException,Microsoft.DistributedFileSystemReplication.Commands.SetDfsrMembershipCommand

I have tried to run this command using dfsradmin and get the same error.  Additionally using the GUI for this last stop results in the same error.

The only work-around I have found is to remove the replicated folder from the replication group and manually re-add it with the GUI (Specifying all the same paths.)

From what searching I've done everything says that the path has an illegal character in it, which it very clearly doesn't.  I've also tried with other folder paths with the same result.

Any ideas?



Viewing all articles
Browse latest Browse all 10672

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>