powershell for home folder owner change
Posted on 2016-07-21
Could you please help me with this.
I have over 500 user home folders on a file share
Current owner of some of those home folders are not the actual user owners. I can see that administrator as current owner on some and some other names as owner of some others home folders. So it is a bit mess to me.
during the account creation, home folder names gets added as %username% in the home folder section in AD.
For reporting purposes ( to identify who is owner of another home folder) and to assign ownership of home folders to actual users, Could you please provide me with a PowerShell to run against \\server\share\users\home ?
for an example;
Mike has a home folder called Mike.Buck if his home folder's owner is administrator or another user, I would like to be informed about it on a excel and meanwhile, current owner must be changed to Mike.Buck. I believe Mike must also have full ntfs permissions to his home folder.