Calculate folder files size skipping .DS_Store Junk

Discussion in 'OS X Mountain Lion (10.8)' started by 2Turbo, Oct 27, 2012.

  1. 2Turbo macrumors 6502

    2Turbo

    Joined:
    Feb 18, 2011
    #1
    I'm trying to figure out the exact folder size in bytes but excluding the system junk .DS_Store files. I want only the size of actual files (not invisible system files).

    The reason is I'm trying to compare two backup hdd's and want to make sure every byte matches to ensure no corruption or missing files. OS X makes this very hard.

    Is there an app that skips calculating the junk files?
     
  2. GGJstudios macrumors Westmere

    GGJstudios

    Joined:
    May 16, 2008
    #2
    Your backups should also include hidden files, so their presence should not cause a discrepancy.
     
  3. Weaselboy Moderator

    Weaselboy

    Staff Member

    Joined:
    Jan 23, 2005
    Location:
    California
    #3
    I think that will be tough to do, since many backup program do exclude quite a few files.

    For example, it you are using Time Machine, you can run the below command in Terminal to see what has been excluded by default by Apple. It is a long list.

    Code:
    sudo mdfind "com_apple_backup_excludeItem = 'com.apple.backupd'"
    If using Carbon Copy Cloner, there is a list here that shows what is excluded by default.

    Most backup programs do something along these lines, so your comparison is not going to match.

    What you may be better off doing is seeing if your backup software has a built in method of verifying a backup. With Time Machine you can option key click the Time Machine menulet and there is a Verify Backups option there.
     

Share This Page