Re: moving /usr to another partition

From: Don Lewis <truckman_at_FreeBSD.org>
Date: Tue, 6 Jul 2004 11:12:50 -0700 (PDT)
On  6 Jul, Charles Swiger wrote:
> On Jul 5, 2004, at 5:50 PM, Don Lewis wrote

>> I'm pretty sure that "restore -r" will do the right thing and just
>> unpack the dump archive into the current working directory.  I'm pretty
>> sure that I've done this in the past.
>>
>> I don't understand the warnings in the man page:
>>
>>      -r      Restore (rebuild a file system).  The target file system 
>> should
>>              be made pristine with newfs(8), mounted and the user cd'd 
>> into
>>              the pristine file system before starting the restoration 
>> of the
>>              initial level 0 backup.
> 
> These warnings are due to the way dump handles files which are hard 
> linked to each other.
> 
> Basicly, the dump format simply archives the inode # used by a 
> hard-linked file, and restore depends on being able to use that same 
> inode # when extracting a tree of files where some of them are 
> hard-linked to each other.  If you restore to a clean filesystem which 
> was freshly newfs'ed, restore doesn't have to worry about the inodes it 
> wants to use already being used by other files.

When restore extracts the file, the inode is quite likely to be
different than before since it is just using open() to create the new
file.  Restore just has to remember the name of the file so that it can
pass it to link() to create the other hard links.
Received on Tue Jul 06 2004 - 16:13:00 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:00 UTC