- Alexander Leidinger - https://www.leidinger.net/blog -

Improv­ing the order of direc­to­ries to back­up in tarsnap

I exper­i­ment­ed a lit­tle bit with the order of direc­to­ries to back­up in tarsnap.

Cur­rent­ly I use the fol­low­ing sort­ing algorithm:

  1. least fre­quent­ly changed directory-trees first
    Every change – even in meta-data – will affect the fol­low­ing data, as tarsnap is doing the de-duplication in fixed-width blocks (AFAIR 64k).
  2. for those directory-trees which change with the same fre­quen­cy: list the big­ger ones first
    Implic­it­ly I assume that the small­er ones are much small­er than the big­ger ones so that the small­er part which will be backed up will not be noticed because of the big­ger change. For my use cas­es of tarsnap this is true.
  3. if changes in a directory-tree are much much big­ger than any­thing else, but the directory-tree has a medi­um change-frequency, put it even before less-frequently chang­ing stuff
    I do not want that a small change trig­gers a big back­up, but a big back­up can con­tain the remain­ing small part.
  4. if you back­up home direc­to­ries (even root’s one) and they do not con­tain much data, put them before directory-trees which change a lot daily
    I do not want that a login trig­gers the trans­fer of data in oth­er directory-trees which have not changed.
[6] [7] [8] [9] [10] [11] [12] [13] [14] [15] [16] [17] [18] [19] [20] [21] [22] [23] [24] [25] [26] [27] [28] [29] [30] [31] [32] [33] [34] [35] [36] [37] [38] [39] [40] [41] [42] [43] [44] [45] [46]Share/Save [47]