HP/DEC/Compaq

tru64 system disk clone

since my disk clone script for irix was quite popular i figured i could also share the one for osf. here it comes:

Code: Select all

########################################################################
#
#   R-A-C OSF/1 AdvFS system disk clone
#
#
#   this script generally assumes disk id 1 and that your target disk is
#   partitioned already. if not run:
#   disklabel -wr -t advfs /dev/rdisk/dsk1c
#
#   then partition your disk using diskconfig or disklabel.
#   this script expects the following partitions:
#   - a: root, rather small.
#   - b: usr, the big one. everything else goes there.
#   - d: swap, not necessary for the cloning.
#
#   if you should not have var as part of the usr domain change the
#   related parts accordingly.
#   if you should use the clone with a different id than the original
#   remember to change the swap entry in /etc/sysconfigtab on the clone.
#
########################################################################


echo preparing ...
rmfdmn -f clone_usr
rmfdmn -f clone_root
cd /mnt
mkdir dr du dv

echo creating clone root domain ...
mkfdmn /dev/disk/dsk1a clone_root
echo creating clone root fileset ...
mkfset clone_root root
mount_advfs clone_root#root /mnt/dr

echo creating clone usr domain ...
mkfdmn /dev/disk/dsk1b clone_usr
echo creating clone usr fileset ...
mkfset clone_usr usr
mount_advfs clone_usr#usr /mnt/du

echo putting var into the usr domain ...
mkfset clone_usr var
mount_advfs clone_usr#var /mnt/dv

echo dumping ...
vdump 0f - / | ( cd /mnt/dr ; vrestore xf - )
vdump 0f - /usr | ( cd /mnt/du ; vrestore xf - )
vdump 0f - /var | ( cd /mnt/dv ; vrestore xf - )

echo fixing domains for the clone ...
cd /mnt/dr/etc/fdmns
mv root_domain root_domain_old
mv usr_domain usr_domain_old
mv clone_root root_domain
mv clone_usr usr_domain

echo cleaning up ...
cd /mnt
umount dr
umount du
umount dv
rmdir dr du dv

echo all done
exit 0
r-a-c.de
Too many versions of the irix clone script show up in search. Can anyone point to the most up to date version?
Torfinn
tingo wrote: Too many versions of the irix clone script show up in search. Can anyone point to the most up to date version?


This is a script for DEC OSF/1 also known as Tru64, not IRIX.
Entire collection up for sale :(
TeamBlackFox wrote: This is a script for DEC OSF/1 also known as Tru64, not IRIX.

i guess he referred to my comment about the irix script in the first post.

tingo wrote: Too many versions of the irix clone script show up in search. Can anyone point to the most up to date version?


the original is there: viewtopic.php?p=65901#p65901
that's also the one i recommend. all modifications that came later did not add actual functionality.
r-a-c.de
foetz wrote: all modifications that came later did not add actual functionality.

Pretty much the story of my life, right there! :lol:
josehill wrote:
foetz wrote: all modifications that came later did not add actual functionality.

Pretty much the story of my life, right there! :lol:

oh did you make on of the later versions? :P
r-a-c.de