On Wed, Sep 03, 2003 at 01:12:25PM +0000 or thereabouts, Mark wrote:
> ----- Original Message ----- 
> From: "Vincent Poy" <[EMAIL PROTECTED]>
> To: "Mike Tancsa" <[EMAIL PROTECTED]>
> Cc: <[EMAIL PROTECTED]>
> Sent: Wednesday, September 03, 2003 2:22 PM
> Subject: Re: Ghost for FreeBSD
> 
> 
> > cd /mnt/root
> > /sbin/dump -L -f- /|restore -rf-
> > cd /mnt/var
> > /sbin/dump -L -f- /var|restore -rf-
> > cd /mnt/usr
> > /sbin/dump -L -f- /usr|restore -rf-
> 
> I have heard this before, but I never understand this part. :) How does
> creating a /mnt/root directory, and restoring in that directory get my /
> slice back? Then the restored data will just sit in /mnt/root! What good
> does it there?
> 
> Or should I create /mnt/root as partition, about equal in size to the root
> partition, and then restore therein, and do the old switcheroo in /etc/fstab
> later, to make it the root partion?
> 
> I have successfully restored /var and /usr, on occasion; but that is rather
> easy, as they can be unmounted. With the root partition, that is not
> possible, of course. Short of having to switch cables on harddisks, is there
> a software method that will allow me to restore/switch the root partion?

To mirror the root partition to another:
# mkdir /mnt/root
# mount /dev/<ROOT-MIRROR-DEV> /mnt/root
# cd /mnt/root
# /sbin/dump -f- / | restore -rf-

You will not *need* to umount the root partition.
(If you wanted to hot-swap between them, I'm not sure it's possible on FBSD.
 There is a ``pivot_root'' syscall on linux, though.)

To mirror another partition, do mostly the same thing, but replace / with
the partition in the dump line (and make sure the correct destination is mounted
on your current directory for the restore).

Dump/restore is pretty much the accepted way of doing this.

-- Josh
_______________________________________________
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to