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

Discussion in 'macOS' started by jennyp, Oct 4, 2012.

  1. jennyp macrumors 6502

    Joined:
    Oct 27, 2007
    #1
    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?
     
  2. wrldwzrd89 macrumors G5

    wrldwzrd89

    Joined:
    Jun 6, 2003
    Location:
    Solon, OH
    #2
    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.
     
  3. jennyp thread starter macrumors 6502

    Joined:
    Oct 27, 2007
  4. ScoobyMcDoo macrumors 65816

    Joined:
    Nov 26, 2007
    Location:
    Austin, TX
    #4
    Do you have ssh access to the linux server? If so, just ssh over there, create a tarball, then download the tarball.
     
  5. jennyp thread starter macrumors 6502

    Joined:
    Oct 27, 2007
    #5
    I just realised I can back up to a case-sensitive disk image. Duh!
     

Share This Page