Date: Wed, 30 Jan 2008 12:12:36 -0600 From: Barry Pederson <bp@barryp.org> To: Mikhail Teterin <mi+mill@aldan.algebra.com> Cc: questions@freebsd.org, fs@freebsd.org Subject: Re: Automatic `nodump' flag? Message-ID: <47A0BE14.3040804@barryp.org> In-Reply-To: <200801301139.21989.mi%2Bmill@aldan.algebra.com> References: <200801301139.21989.mi%2Bmill@aldan.algebra.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Mikhail Teterin wrote:
> Hello!
>
> I'd like the entire contents of each user's .mozilla/firefox/*/Cache directory
> to be excluded from the regular filesystem dumps.
>
> Running ``chflags -R nodump /home/*/.mozilla/firefox/*/Cache'' does the trick,
> but this needs to be redone daily -- prior to running the backup -- because
> new entries appear in the caches, obviously... The new entries don't have the
> nodump flag set.
>
> Is there a way, the flag can be set automatically? For example, inherited from
> the directory? Thanks!
The dump man page for 6.2 says:
Directories and regular files which have their ``nodump'' flag
(UF_NODUMP) set will be omitted along with everything under such
directories, subject to the -h option.
So if the "Cache" directories themselves are flagged, I think you'd be
OK. Maybe
chflags nodump /home/*/.mozilla/firefox/*/Cache
(without the -R) would be a good thing to quickly make sure the
directories are flagged in case the users delete/recreate the Cache
folders, but wouldn't take as long as flagging each and every cache file.
You'd probably also want to add "-h 0" to the dump args, otherwise the
cache files would be included in level 0 dumps.
Barry
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?47A0BE14.3040804>
