Hello, I'm running a 6.1-PRE machine and have created the following scripts called from /etc/crontab : 0 0 * * * root /usr/local/sbin/make_snapshot.sh 15 0 * * * root /usr/local/sbin/purge_snapshot.sh make_snapshot.sh : #!/bin/sh date=`date +%d-%m-%y` /sbin/mksnap_ffs / /.snap/snapshot-$date purge_snapshot.sh: #!/bin/sh /usr/bin/find /.snap -name "snapshot-*" -type f -ctime +7d -exec /bin/rm '{}' \; so i will have snapshot created each day, and all snapshots older than 7 days will be deleted. but i have more than 7 files in /.snap : ls -la /.snap/ total 125460 drwxrwxr-x 2 root operator 512 Feb 28 00:00 . drwxr-xr-x 19 root wheel 512 Feb 27 13:08 .. -r--r----- 1 root operator 536870984 Feb 28 09:36 snapshot-20-02-06 -r--r----- 1 root operator 536870984 Feb 28 09:36 snapshot-21-02-06 -r--r----- 1 root operator 536870984 Feb 28 09:36 snapshot-22-02-06 -r--r----- 1 root operator 536870984 Feb 28 09:36 snapshot-23-02-06 -r--r----- 1 root operator 536870984 Feb 28 09:36 snapshot-24-02-06 -r--r----- 1 root operator 536870992 Feb 28 09:36 snapshot-25-02-06 -r--r----- 1 root operator 536870992 Feb 28 09:36 snapshot-26-02-06 -r--r----- 1 root operator 536870992 Feb 28 09:36 snapshot-27-02-06 -r--r----- 1 root operator 536870992 Feb 28 09:57 snapshot-28-02-06 and most of them are with the same timestamp? Any ideas? Probably i'm doing something wrong, but can't see it yet... Regards, Niki
Hi On Tue, 28 Feb 2006 10:40:36 +0200, Niki Denev <nike_d@cytexbg.com> wrote:> Any ideas? Probably i'm doing something wrong, but can't see it yet...Tri it. DIR=/.snap nice sh -c "cd $DIR ; rm -rf `date -v-7d +'snapshot-%d-%m-%y'`" ----+----1----+----2----+----3----+----4----+----5----+----6----+ NAKAMURA Takeshi <1yen@sh.rim.or.jp> I have poor english.
On Tue, Feb 28, 2006 at 10:40:36AM +0200, Niki Denev wrote:> Hello, > > I'm running a 6.1-PRE machineSo why haven't you tested the quota patch I posted, since you posted a month ago about quota deadlocks? ;-) Kris -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: not available Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20060228/98936510/attachment.bin