>>>>> "D" == D Cooper Stevenson <[EMAIL PROTECTED]> writes:

D> All, Here's the scenario: you need a backup solution that will make
D> a complete backup of your server and automatically rotate the
D> backup snapshots using rsync.

D> These two scripts will take a snapshot once every four hours
D> (depending on your crontab entry) and automatically rotate the
D> snapshots "backward," that is, 'hourly.3' will be deleted,
D> 'hourly.2' will rotate to 'hourly.3,' 'hourly.1' will rotate to
D> 'hourly.2' and so on.

But why throw _anything_ away until you are out of media?  Free space
is wasted space, I always say.  My locally hacked solution to do
basically the same thing just kept all snapshots, but the script would
ensure enough space by deleting the oldest snapshots until the space
needed was available.  Instead of rotating hourly.N naming, I just had
a /snapshots/<tree>/YYYYMMDD-HHMM/ naming (year, month, day, hour,
minute, respectively) and could easily figure out which was oldest by
sorting appropriately.

What the rsync solution was missing the last time I looked was a
--dry-run (or similar) option that would report how much disk space
you needed to make your snapshot, so that you had a target number you
could use to free adequate space.

-- 
Russell Senior         ``shtal latta wos ba padre u prett tu nashtonfi
[EMAIL PROTECTED]      mrlosh''  -- Bashgali Kafir for ``If you have
                         had diarrhoea many days you will surely die.''
_______________________________________________
EuG-LUG mailing list
[EMAIL PROTECTED]
http://mailman.efn.org/cgi-bin/listinfo/eug-lug

Reply via email to