Re: Automatic `nodump' flag?



Date: Wed, 30 Jan 2008 16:13:54 -0600
From: Barry Pederson <bp@xxxxxxxxxx>
To: Kirk McKusick <mckusick@xxxxxxxxxxxx>
CC: =?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?= <des@xxxxxx>, questions@xxxxxxxxxxx,
fs@xxxxxxxxxxx
Subject: Re: Automatic `nodump' flag?
X-ASK-Info: Message Queued (2008/01/30 14:14:17)
X-ASK-Info: Confirmed by User (2008/01/30 16:37:01)

Kirk McKusick wrote:

The dump program runs on the raw disk partition dumping sequentially
by inode number. So, it has no idea of the file-tree hierarchy.

I was just looking at the source to dump, specifically traverse.c and
from what I can see, doesn't dump pass #2 scan through all directories
and then in the searchdir() function remove a directory's children from
the list of inodes to backup if the directory has the nodump flag?

---------
414 if (nodump) {
415 ip = getino(dp->d_ino, &mode);
416 if (TSTINO(dp->d_ino, dumpinomap)) {
417 CLRINO(dp->d_ino, dumpinomap);
418 *tapesize -= blockest(ip);
---------

Barry

You are completely correct. This does prune out everything below a
directory marked `nodump' even if those files are not also marked
`nodump'. Note that by default, level 0 dumps will ignore the
`nodump' flag. You have to use `-h 0' if you want a level 0 dump
to honor the `nodump' flag.

You would think I would remember code that I wrote (though in my
defense it was written over 20 years ago :-)

Kirk McKusick
_______________________________________________
freebsd-questions@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: Automatic `nodump flag?
    ... Subject: Automatic `nodump' flag? ... directory to be excluded from the regular filesystem dumps. ... any propagation of the "nodump" flag would have to be done by the ...
    (freebsd-questions)
  • nodump on directories: new contents still dumped
    ... The other scripts for dumps>0 do not have a -h flag ... cron) do not have the 'nodump' flag set. ... I understood that dump does not enter directories with 'nodump' flag set, ...
    (freebsd-questions)
  • Re: How to avoid ufsdump-ing certain files on Solaris?
    ... On BSD a file can be marked with "nodump" flag ), ... the dump will skip it. ...
    (comp.sys.sun.admin)
  • Re: nodump on directories: new contents still dumped
    ... The other scripts for dumps>0 do not have a -h flag ... cron) do not have the 'nodump' flag set. ... i dump my machine to tape drive using this flags and works as expected. ...
    (freebsd-questions)
  • Re: Automatic `nodump flag?
    ... any propagation of the "nodump" flag would have to be done by the ... raw filesystem. ... there is enough to set nodump flag to directory, and no files in it will be backed up ...
    (freebsd-questions)