On Sun, 22 Oct 2006 15:39:14 -0500
Michael Sullivan <[EMAIL PROTECTED]> wrote:

> On Sun, 2006-10-22 at 12:44 -0500, Jim Reimer wrote:
> > 
> > Instead of deleting from the previous weeks tarball the files that
> > haven't changed, why don't you just make this week's include only the
> > files that have?
> > 
> > tar --after-date
> > tar --newer
> > tar --newer-mtime
> > etc.
> > 
> > -- 
> > -jdr-
> 
> Because a Sunday's full backup needs to stay a full backup until the
> following Sunday when another full backup is made, in case something
> goes wrong.  That's why they're made once a week.  Unfortunately, I
> can't afford the storage (blank CDs or places to store the CDs after
> they've been written), which is why I do it this way.  I don't edit an
> older full backup until I have a newer full backup.

Either we're not getting something here, or you aren't. Rather the
latter. You do full backups on Sundays and incrementals in between.
That's just what the --after and --newer options will do for you.

Quick and dirty solution with cron:

0 1 * * 0       root    rm /backup/full* /backup/incremental*
0 2 * * 0       root    tar -cjvf /backup/full-`date +%Y-%m-%
d`.tar.bz2 /what/you/want/to/backup
0 2 * * 1-6     root    tar -N `ls /backup/full* | sed -rn
's/\/backup\/full-(.*).tar.bz2/\1/p'` -cjvf /backup/incremental-`date +%
Y-%m-% d`.tar.bz2 /what/you/want/to/backup

This would delete your backups at 1 on sunday, make a full backup at 2
on sunday, and do incrementals at 2 each day except sunday. The date
when a backup was made is stored in the filename, and in case of a full
backup it's parsed out and used as a value for the --newer option to
tar.

Of course, it would be much more elegant to write a script that does
all this instead of having a hardly intelligible line like this in your
crontab.

Cheers
-- 
Horror Vacui

War Is Peace
Freedom Is Slavery
Ignorance Is Strength


To unsubscribe from this list, please email [EMAIL PROTECTED] & you will be 
removed. 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/LINUX_Newbies/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/LINUX_Newbies/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[EMAIL PROTECTED] 
    mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 

Reply via email to