Link to home
Start Free TrialLog in
Avatar of HomerTNachoCheese
HomerTNachoCheese

asked on

Change file ownership of only admin-owned files

I want to find a way to change the ownership of entire folders and their contents to a specific user, but only change ownership where files and folders are currently owned by "BUILTIN\Administrators."  I don't want to change existing ownerships if some files within these folders are already owned by specific users.

Does anyone know of a way of accomplishing this?  

I am guessing that the ownership was set to administrators when file servers were changed, and certain file attributes were lost in the file transfer.
SOLUTION
Avatar of Wilder_Admin
Wilder_Admin
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of HomerTNachoCheese
HomerTNachoCheese

ASKER

Wilder - your solution may work, but I want to try something free first.  I was taking a look at subinacl.exe, but I am not sure if that would work.  Points should come your way after I collect more feedback from others :)

I suppose a script that I would need to build, if there are no free utilities out there, would be a script that first outputs a list of folder contents that belong to the admin to a temp file.  Then, for each file run subinacl (or a similar executable) that sets the new owner.  If anyone has suggestions along those lines it would be appreciated.
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I think my solution is the best solution because of price (free).  It has many manual steps, but I can live with that.  I am sure there are ways to throw this whole process into a batch file, eliminating the Excel steps and Notepad steps completely.  

Wilder - your solution appears it will work just as well, and probably be much more user-friendly at the same time, therefore, you get some points!