SUMMARY : How to restore 2 filesystems to one partition

From: jean.schuller <schuller_at_sbgal4.in2p3.fr>
Date: Thu, 13 Aug 1998 10:35:27 +0100 (GMT+0100)

        Hi all,

        So fast , so good.

        JEAN.

        Many thanks to

--> Thomas Leitner who wrote :
I think you do not need to boot from the CD! As your root partition
stays intact, you could as well boot into single user mode and make
the modifications from there as /usr and /usr1 are not used in single
user mode anyway.

Restoring can be done as well from single user mode as vrestore
lives under /sbin/vrestore which is in the / partition.

To restore you'd need commands like this after you have changed
the partition table and rebooted:
# newfs ..... for making the new /usr partition
# mount /usr
# vrestore -x -f .... # for restoring the /usr tape
# mkdir /usr/usr1
# vrestore -x -f /.... -D /usr/usr1 # for restoring the /usr1 tape

now, your files which were priviously under /usr1 are now under /usr/usr1
and you can move them whereever you want them to be.

BTW: Before repartioning the disk I would try to do an interactive
restore with vrestore from single user mode just to be sure that
vrestore works and can read the save-set.
Something like

# vrestore -i -f .....
and see if you can "ls" your files


--> TONY MILLER who wrote :
If you are uncertain as to which file set is / and /usr, use appropriate
combinations of the following commands. Note use of the rewind and no
rewind devices:
> mt -f /dev/rmt0a rewind
> vrestore -tvf /dev/nrmt0a !Lists 1st file set
> mt -f /dev/rmt0a rewind
> mt -f /dev/nrmt0a fsf 1 !Skip to 2nd file set
> vrestore -tvf /dev/nrmt0a !Lists 2nd file set
> mt -f /dev/rmt0a rewind
> mt -f /dev/nrmt0a fsf 2 !Skip to 3rd file set
> vrestore -tvf /dev/nrmt0a !Lists 3rd file set


Restore the /usr file system. Note the use the rewind and no rewind tape
devices. This restore will take approximately 40 minutes to complete.
>mt -f /dev/rmt0a rewind
>mt -f /dev/nrmt0a fsf nn !Skip to file set nn (/usr)
>vrestore -xvf /dev/nrmt0a -D /usr
>mt -f /dev/rmt0a rewind
>mt -f /dev/nrmt0a fsf nn+mm !Skip to file set nn+mm (/usr1)
>vrestore -xvf /dev/nrmt0a -D /usr


MY ORIGINAL QUESTION :
======================

       On one of my alphas, I have the following Filesystems :

/dev/rz0a 253278 136608 91342 60% /
/dev/rz0h 5121226 762048 3847054 17% /usr1
/proc 0 0 0 100% /proc
/dev/rz0g 1985038 1458080 328454 82% /usr


        For different reasons, I have to reinstall this station.
        This time, I want to have only "one" filesystem /usr on /dev/rz0g.

        I made a backup from /usr and /usr1 to a tape with rsh
        /sbin/vdump -0 -u -b 60 -f - /usr | rsh st4 dd of=/dev/nrmt0h bs=60k"
        /sbin/vdump -0 -u -b 60 -f - /usr1 | rsh st4 dd of=/dev/nrmt0h bs=60k"
        After booting my alpha from the CD, I expect to do :
        disklabel rz0a for /
                  rz0b for swap
                  rz0c for the whole disk size
                  rz0g for /usr

        My question is : how can I vrestore these 2 filesystems /usr and
        /usr1 from the tape to one filesystem /usr ??
 
-----------------------------------------------------------------------------
jean.schuller_at_ires.in2p3.fr _/ _/_/_/ _/_/_/ _/_/_/_/
                                _/ _/ -/ _/ _/ _/
                               _/ _/_/_/-/ _/_/_/ _/_/_/_/
                              _/ _/ -/ _/ _/
                             _/ _/ _/ _/_/_/ _/_/_/_/
local call: 0388106630 Institut de Recherches Subatomiques
foreign call: (33)388106630 Boîte Postale 28
local fax : 0388106234 23, Rue du Loess
foreign fax : (33)388106234 F-67037 STRASBOURG CEDEX - France
-----------------------------------------------------------------------------
Received on Thu Aug 13 1998 - 08:34:07 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:38 NZDT