misty Rated XXX
|
Posted: Wed, 08 Dec 2004 15:23:41 Post Subject: |
|
|
Okay.. ignore me if you want to, but here's how you could make an archive.
#!/bin/ksh (where ever ksh is located)
FILENAME=dir.tar.`date +%m%d%Y`.tgz
tar -cvzf $FILENAME dir/
To write to another drive:
tar -cvzf $FILENAME /disk2/archive/$FILENAME
To cleanup your backups older than seven days you could run this script daily via cron.
find /dir/path -name "dir.tar*" -mtime +7 -exec rm {} ;
Something like that.. I think that will work, I just came up with it so it's never been tested. _________________ Meg: Everybody! Guess what I am?
Stewie: Hm, the end result of a drunken back-seat grope-fest and a broken prophylactic?
Stewie: I was under the impression the name of the show was "Kids Say the Darndest Things," not "Old Black Comedians Never Shut the Hell Up." |
|