Applying complex NTFS permissions to existing folder structure
Posted on 2008-11-17
I'm looking for some advice on applying a complex set of NTFS permissions to an existing set of folders, and was wondering if anyone here could help me out.
We have a Windows 2003 domain with workstations using Windows XP, and the folders are shared from a Windows 2003 Standard server.
We currently have an example of the folder structure with proper permissions created on the server and a batch file that certain users can run to copy those folders from the "template" folder to the "production" folder. This batch file uses robocopy with the /copyall switch to copy permissions and ownership from the template folder to the production folder and renames the new root folder as the job name.
A while ago something went wrong with this batch file and a bunch of jobs got created with the wrong permissions. On top of that, the permissions were slightly changed by management so now ALL of the existing jobs in the production folder need to be updated with the new security. Here is a simplified example of the structure, so you'll know what I mean:
-New Job Template root Folder
So, the Group1 Active Directory group has rights over the group1 folder and all subfolders, Group2 has rights over group2, etc. Some of them have more rights specified further down, but luckily all of them share the basic folder structure.
So, my main question here is: Is there any way to take my existing security and ownership on the template folders and apply it to the Jobs that were created incorrectly without overwriting any files?
I really don't want to go through every job and correct the permissions, so I'd love an automatic way of handling this (especially if this ever happens again).
Thanks in advance for any help you can provide.