How to backup case-sensitive Linux files to OS X's HFS+

jennyp

macrumors 6502
Original poster
Oct 27, 2007
469
67
I've got trouble backing up my website using an FTP client.

What I normally do is select all the remote files in the FTP client (say, Transmit) and drag them to a folder on my desktop, and when they're all downloaded I later zip the folder and store it for backup.

But the server which holds my website files is running Linux so that files are case-sensitive. So "my_picture.jpg" and "My_Picture.JPG" on the Linux box are different files.

But on OS X with HFS+ the files are case-insensitive, so that my_picture.jpg" and "My_Picture.JPG" are considered the same file.

The result is that the FTP client whilst downloading says "Whoops, these files are the same, what do you want to do," etc.

Is there any straightforward way I can backup these case-sensitive files to my Mac?
 

wrldwzrd89

macrumors G5
Jun 6, 2003
12,107
75
Solon, OH
The one method I know will work is this:
  1. Connect an external device to your Mac, larger than the data to back up. External HDD, USB thumb drive, doesn't matter a whole lot as long as it can be formatted.
  2. Format it in Disk Utility with the HFS Plus (Case-sensitive, Journaled) option.
  3. Copy the files from the FTP client to this external device.
  4. Use a 7-zip program to create the archive, adding as an extra parameter the -ssc option (set sensitive case): BetterZip and 7zX are two programs that can do this.
Dealing with case-sensitive files on a system that is NOT case-sensitive is a royal pain.
 

jennyp

macrumors 6502
Original poster
Oct 27, 2007
469
67
I just realised I can back up to a case-sensitive disk image. Duh!
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.