How do I reduce the size of my Time Machine's Sparse Disk Image Bundle?

Discussion in 'Mac Basics and Help' started by maclook, Sep 20, 2009.

  1. macrumors 65816

    Joined:
    Nov 2, 2008
    #1
    I've deleted 6 backups already and am left with three but the size of the file hasn't changed at all. I don't want to delete the whole thing and start over.

    The file size now is 330gb which is ridiculous to me that it hasn't changed one bit since i deleted 6 backups.
     
  2. macrumors regular

    dragonmantek

    Joined:
    Oct 16, 2007
    Location:
    New York
    #2
    format the drive, if you don't have any big files to backup, and then reset the time machine settings to whatever you want, and re-do the whole thing.
     
  3. thread starter macrumors 65816

    Joined:
    Nov 2, 2008
    #3
    so are you telling me to pretty much erase everything and start over? i dont want to do that. the drive is a time capsule and i have files other than the disk image on there that i want to keep.

    i have a 120gb drive on my macbook. if i delete every backup but one and the sparse bundle is still 330gb will that make absolutely no sense? i'm deleting backups using the gear in finder when in time machine which i think is the correct way
     
  4. macrumors regular

    Joined:
    Oct 11, 2007
    Location:
    Schaumburg
    #4
    Well now is the time to think about what could be taking up that space in the sparse bundle. DO you use any software that uses a database or stores everything in a single file. Examples of this are Microsoft Entourage, FileMaker documents, Parallels or VMWare Fusion virtual machines?
     
  5. macrumors 68030

    Joined:
    Nov 7, 2004
    #5
    No need to reformat.

    hdiutil compact /path/to/xxxxx.sparseimage

    should do the trick.
     
  6. thread starter macrumors 65816

    Joined:
    Nov 2, 2008
    #6
    is that a terminal command?
     
  7. macrumors 68030

    Joined:
    Nov 7, 2004
    #7
    Well, it's not a GUI, so doesn't leave much else.
     
  8. macrumors newbie

    Joined:
    Dec 9, 2009
    #8
    Wrong!

    A Sparse Disk Image - first is a Mac format compression file.

    Second - A Sparse Disk Image is designed to start out small and expand as files are added to the Sparse Disk Image. It is not designed to deflate as files are removed. Such as is the case with a standard Folder.

    In order to shrink the size of the Sparse Disk Image back down - you do have to manually [or thru automation] as weckart mentioned run a Terminal command to tell the system to recompress the file size to clear up unused free space.

    Read before you speak!
    http://en.wikipedia.org/wiki/Sparse_disk_image

    Not really too much to do with Microsoft or VM [virtual machines] databases. Databases have less hassle resizing themselves and even still have protocols built in to regulate this most times. There does however have to be a database controlling Time Machine to keep everything organized but it's a separate mechanism within Time Machine. 2 different things.
     
  9. macrumors member

    Joined:
    Aug 12, 2008
    #9
    I am not used to using Terminal, so a GUI would be great (especially when I don't know the actual written 'path' for the Time Capsule) but I did find this from MurphyMac.com.

    "...Here’s a tip in case you’re not used to working with Terminal. Just type hdiutil compact in the Terminal, followed by a space. Then drag the sparse image file from Finder into the Terminal window. The path and file name will be added to the command line. Hit the Return key on the keyboard and you’re done."
     
  10. macrumors newbie

    Joined:
    Jul 11, 2010
    #10
    Awesome

    Very nice, very nice. My sparse image was in a network drive and I didn't know how to place the whole location in the terminal. I tried to use the disk utility and couldn't compact for some reason (even after ejecting). The tip you provided was great, the drag and drop worked fine and I saved 100Gb of disk by compacting! :cool:
     
  11. macrumors newbie

    Joined:
    Nov 28, 2012
    #11
    help needed on this solution

    I see your solution worked for others.
    Personaly I found problem.
    I'm not specialist and in Terminator app I had this:

    << Last login: Wed Nov 28 14:59:42 on ttys000
    MacBookProTI:~ tignaciuk$ hdiutil compact /Volumes/terra-1/MacBookProTI.sparsebundle
    hdiutil: compact failed - Function not implemented
    MacBookProTI:~ tignaciuk$ >>


    can you (or somebody else) help on this
     
  12. macrumors 6502

    Joined:
    Apr 9, 2006
    Location:
    Boston, MA
    #12
    I just actually ran into this problem today and was looking for an answer to this. Are you using a laptop not connected to battery power when doing this? If so, you either have to connect it to batery power or use the following command
    Code:
    hdiutil compact -batteryallowed /path/to/name.sparseimage
    I'm guessing it's to prevent data corruption in the case of loss of power.
     
  13. macrumors newbie

    Joined:
    Jul 10, 2009
    #13
  14. macrumors newbie

    Joined:
    Jul 10, 2009
    #14

Share This Page