December 15th, 2009


How to remove "extended attributes" from a manually restored Time Machine backup in OS X

This took me way too long to work out, so I'm dropping it here for future reference.

Time Machine does not create ACLs - Access Control Lists - in its backups. Instead it adds "extended attributes" to each file and folder, which is something different. If you restore these files by hand, by copying them straight onto your hard drive, the extended attributes are carried along and will prevent you from altering the files later.

To remove the attributes that Time Machine creates, these two commands will work:

find . -print0 | xargs -0 xattr -d
find . -print0 | xargs -0 xattr -d

Run them as root, and at the base of the tree you want to clear.