[Dirvish] A suggestion for dirvish-expire
dhoworth at mrc-lmb.cam.ac.uk
Wed Dec 5 10:00:39 UTC 2012
Hernán J. González wrote:
> This works, and might seem ingenious. Actually, it's terribly fragile,
> it's a nightmare to maintain - or a bomb waiting to explode
> Suppose someday you want to change your backup schedule, and you start
> running dirvish on Sunday-Tuesday-Thrusday. You're doomed. You can't do it.
> And if you do it and naively change the '5' (week day) in
> your expire-rules to '4' ... ooops... you've lost all your old backups.
> (And if you don't change them, the new backups will expire after 10 days)
Either you or I misunderstands how expiry works. I think dirvish
calculates the expiry date when it creates each backup and stores it in
the summary file. dirvish-expire just checks that date, so changing the
day on which you run dirvish makes absolutely no difference to backups
that already exist.
> Another useful (orthogonal) option to dirvish-expire would be to
> look for some special file inside the vault that works as a "dont ever
> expire me" flag.
It already exists. If you change the expiry date in the summary file to
a century in the future, that's what it will do.
As Ken says, though, if you write a useful new expiry program that
behaves as you wish then people will use it. There's no need to change
the behaviour of the existing programs (i.e. 'break' them)
More information about the Dirvish