10.6: Use Archive Utility to make zip backups

Oct 05, '10 07:30:00AM

Contributed by: ojohns

Snow Leopard only hintFor those who don't trust Time Machine, backing up to archives manually can be tricky. First off, as of OS X 10.6.4, the Unix zip and unzip programs that you can start from a terminal shell script do NOT handle resource forks and extended attributes correctly. The zip man file has an apology that this will be implemented soon. (And Automator uses the Unix zip program.)

The tar archiver also does not handle extended attributes correctly. It also saves but does not restore resource forks. So that is not useful either.

It seems that the Archive Utility.app that makes archives for the Finder is ahead of the Unix zip and tar. It DOES handle resource forks and extended attributes correctly.

But using the Archive Utility from the Finder is clumsy and unreliable when there are several folders to archive. If you select a range of folders, and then right click one of them and select Compress, it will make one big zip file rather than individual zip files for each folder. But if you right click on one folder after another to archive them separately, the Finder gets confused and some of the archives quit with errors.

The only work around seems to be to wait for each archive to finish before starting the next. This can take hours of attention. Fortunately, there is a better way.

The utility will make individual zip archives of A, B, C, ..., Z and place them in /Users/YOURNAME/YOURARCHIVEDIR. If there are more than four, the archive utility will make them four at a time.

It seems to handle the manipulation of multiple folders well -- no errors. These seem to be the same zip archives as would be made if you right clicked the folders A, B, ... , Z in succession in the Finder and chose Compress 'A', etc. individually. And it seems that the preferences you set in Archive Utility do not affect its behavior when used from the Finder right click menu.

[crarko adds: I haven't tested this one. This is the first I've heard that in 10.6.4 the version of zip mangles resource forks. Can someone confirm this? I think even if it's not correct, the hint itself still has utility.]

Comments (16)

Mac OS X Hints