PowerShell DSC SmbShare error: No mapping between account names and security IDs was done

59 views Asked by At

I have a PowerShell DSC script that I'm using to setup a server.

The script looks something like this:

Configuration Server
{
 Import-DscResource -ModuleName ComputerManagementDsc
 Node "localhost"
 {
  File MyFolder
  {
    Ensure = 'Present'
    Type = 'Directory'
    DestinationPath = "D:/myFolder"
  }

  SmbShare MyShare
  {
    Name = "My Shared Folder"
    Path = "D:/myFolder"
    Description = "My shared folder"
    ConcurrentUserLimit = 16777216
    DependsOn = "[File]MyFolder"
    Ensure = 'Present'
    ChangeAccess = @("mySubDomainInForest\KnownGroup")
    FullAccess = @("mySubDomainInForest\KnownSecondGroup")
    ReadAccess = @("Users")
    Force = $true
  }
 }}

When I apply the DSC script to the server I'm getting the following error:

No mapping between account names and security IDs was done.

This results in the Read Access permissions to be applied but change access and full access permissions don't get applied. The "Users" are the users local to the machine, whereas the other two are domain groups.

Your help is much appreciated.

0

There are 0 answers