FYI: Simple backup/restore of NTFS ACL, owner info, and auditing info

  • Thread starter Frank-Peter Schultze
  • Start date
F

Frank-Peter Schultze

Hello, World!

searching for a quick and simple way to backup file/folder security
(NTFS ACLs), ownership information, and auditing information I
discovered ROBOCOPY's ability to copy these informations w/o copying
the file data.

To backup a complete directory tree or partition use the following
robocopy switches:

/E copy subdirectories, including Empty ones.
/COPY:copyflag what to COPY. (copyflags : D=Data, A=Attributes,
T=Timestamps, S=Security=NTFS ACLs, O=Owner info,
U=aUditing info; we need S, O, and U).
/CREATE CREATE directory tree and zero-length files only.

Example:

ROBOCOPY X:\ Y:\ACL.BAK\X\ /E /COPY:SOU /CREATE

This will create drive X's directory tree and 0 byte files in
Y:\ACL.BAK\X with their ACLs, owner info, and auditing info.

To restore this information type:

ROBOCOPY Y:\ACL.BAK\X X:\ /E /COPY:SOU /CREATE

Don't panic. This won't overwrite drive X's files w/ 0 byte files
because the the copyflag D (=Data) is not used.

I tested this using ROBOCOPY version XP010. Of course, this method has
its limitations. For example, the copy destination must be located on
a NTFS formatted partition.

Regards
fps

--
Frank-Peter Schultze [http://www.fpschultze.de]

Disclaimer: I make no guarantees or warranties, express, implied or of
any other kind to this code or any user modifications. Do not use in a
production environment until you have tested in a secured lab
environment. Use at your own risk.
 
C

Clay Calvert

Hello, World!

searching for a quick and simple way to backup file/folder security
(NTFS ACLs), ownership information, and auditing information I
discovered ROBOCOPY's ability to copy these informations w/o copying
the file data.

That's a good technique to know.

Thanks

Clay Calvert
(e-mail address removed)
Replace "W" with "L"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top