Hello,
It is expected behavior not only when you move home folders between servers, but also when you move a home folder from one share to another within the same server. As a workaround, we can suggest adding one more action to your Business Rule that moves home folders. The action will automatically grant Full Access permissions to a user for his/her home folder after the folder move.
For information on how to add an action to a Business Rule, see steps 5 and 6 of the following help article: http://www.adaxes.com/help/?ManageBusin ... tions.html. You'll need to:
-
Add the Run a program or PowerShell script action.
-
Paste the following script in the Script field:
# Get home directory folder
try
{
$homeFolder = $Context.TargetObject.Get("homeDirectory")
}
catch
{
$Context.LogMessage("The user does not have a home directory.", "Warning") # TODO: modify me
return
}
# Get the user's SID
$userSidBinary = $Context.TargetObject.Get("objectSid")
$userSid = New-Object System.Security.Principal.SecurityIdentifier($userSidBinary, 0)
# Grant Full Access to the user for the home folder
$homeFolderACL = Get-Acl $homeFolder
$acl = New-Object System.Security.AccessControl.FileSystemAccessRule($userSid,"FullControl","ContainerInherit,ObjectInherit","None","Allow")
$homeFolderACL.AddAccessRule($acl)
Set-Acl -path $homeFolder $homeFolderACL
-
Enter a short description for the script and click OK.
-
Save the Business Rule.