February 18th, 2010

OS X Error -36 & Compress Bug

The dot_clean terminal command can fix some of the problems OS X creates for itself by using dot underscore files to store folder content information. I have recently encountered two problems due to this. Last week I was not able to copy files to a FAT32 formatted PC USB drive. Attempting to spit out the unhelpful Error -36. Only a few days later I was unable to successfully compress data using the right-click Compress command. It hung when reaching 99.5%. The dot_clean command used in terminal fixes both issues.

Error -36

I had been working on some GIS data in Windows last week and backed up my data onto my mac. Today as I was trying to move the files from my mac to a USB stick I encountered the extremely frustrating error:

The Finder can’t complete the operation because some data in “Data” can’t be read or written. (Error code -36)

None of the files could be copied to my USB drive. I went online searching for a solution and finally after finding many posts of people having similar issues yet never getting an intelligent reply I finally found the solution at macyourself.com.

It turns out it’s Snow Leopard’s fault at poorly handling PC formatted files. The terminal command dot_clean happily and instantly repairs the data so you can merrily move it around again.

In terminal simply type the command and path to the offending folder:

dot_clean /Users/Cyrille/Documents/Data

Compress “File” Hangs

Again using GIS data, I attempted to compress a folder to back it up. I right clicked on the folder and clicked Compress “Data”. It very quickly reached 99.5% complete before hanging – permanently. This is caused by the Compress command having some issues with files starting with a dot followed by underscore (._filename). Again the dot_clean command causes these to be absorbed into the relevant files. Simply run the dot_clean command on the folder you are trying to compress as I did above:

dot_clean /Users/Cyrille/Documents/Data

You can now compress your data as you originally tried and it should quickly provide you with a compressed archive.

Tags: , , ,

Leave a Reply