Hi, I have done this successfully, but it's quite complicated - here are my notes, based on root and var partitions only.
Some of this may be more detailed than you need.
Regards, Mike
· Boot from the Solaris8 cd.
· Configure and restore root and var file systems
· Boot from the recovered Unix system.
· Configure the remaining disks and restore all remaining data.
· Boot to normal running in multi-user mode.
Select a boot disk. Usually c0t0d0. Set up slices on this disk for root, var and swap, and any other file systems. See ‘df –k’ from the source machine for sizes. swap is 2 or 3 time RAM – exact figure is not critical.
EG root slice 0 3Gb
swap slice 1 9 Gb
var slice 3 500 Mb
Note slice 2 is normally left as a ‘backup’ slice. (Not used )
On the remaining disks, allocate disk partitions to disks, depending on the disk sizes.
Check these figures against the ‘df –k’ listing from the source machine.
Boot from cd (into Single user )
insert Solaris8 Software (1 of 2) cd
boot cdrom -s
Select option ‘Exit to single user shell’
“Do you want to format disk……”
Select ‘No, exit to single user shell’
Set up root, var, swap
List available disks (not tested when booted from cd)
iostat –En
These notes assume that the root disk is c0t0d0.
Format the root disk.
Use the format command. Use the partition sizes from the df –k (or prtvtoc output) listing to create root, swap and var partitions. The root partition should be c0t0d0s0, c0t0d0s1 should be a swap partition and c0t0d0s3 should be the var partition.
Build ufs file-systems on root and var partition, not on the swap slice.
newfs /dev/dsk/c0t0d0s0
newfs /dev/dsk/c0t0d0s3
Install boot block on root partition.
cd /usr/platform/sun4u/lib/fs/ufs
installboot bootblk /dev/rdsk/c0t0d0s0
mount root on /mnt
mount var on /mnt/var
restore root and /var
It is not possible to give precise commands to do this. Use a combination of these for ufs restore.
mt -f /dev/rmt/0 rewind rewinds the tape
dd if=/dev/rmt/0 Check tape contents – reads file 0 on tape, so this should follow a rewind.
cd /mnt NB ufsrestore command will restore
into current directory.
mt -f /dev/rmt/0n fsf 1 Wind tape forward by 1 file.
mt -f /dev/rmt/0n asf N Wind tape forward to absolute file
position N.
ufsrestore rf /dev/rmt/0cbn restore root current file into current directory
Note that restore is very slow when system is booted from cd - root restore up to 2.5 hours.
cd /mnt/var
ufsrestore rf /dev/rmt/0cbn restore var (having set tape to
correct position)
ufsrestore if /dev/rmt/0cbn Interactive restore.
EG You are restoring root (file 1 on tape) into /mnt (the newly created file-system)
cd /mnt
Load tape
mt -f /dev/rmt/0 rewind To start at the beginning.
dd if=/dev/rmt/0 To Print an index. Tells you that
root (/) is tape file 1, and /var is tape file 2.
mt -f /dev/rmt/0n asf 1 Go to tape file 1
ufsrestore if /dev/rmt/0cbn See “man ufsrestore” for details.
ls Shows files on tape.
add . Tapes to be restored have to be selected first, with the
add command. “add .” adds everything, “del abc”
removes abc from the list. The files to be restored are marked with “*” characters. In this case, add everything, then remove lost+found from the list.
add .
del lost+found
ls to check
When the list is correct, “extract” will start the restore. To the question “Specify next volume £: “, answer “1”.
When the restore is complete, ufsrestore asks “set owner/mode for '.'? [yn]”. Answer “n”. (or “y” – it doesn’t seem to matter much)
quit.
cd to the next file-system, and wind the tape to the next tape file you want to restore, and run ufsrestore again.
Set up devices for the ‘new’ hardware.
Backup /mnt/devices/pseudo
cd /mnt/device
mv pseudo pseudo.today
Remove all directories (everything) in /mnt/devices except pseudo.today
Remove entries in /mnt/dev/dsk,
/mnt/dev/rdsk,
/mnt/dev/rmt.
Remove /mnt/etc/path_to_inst
Recreate config info
drvconfig –p /mnt/etc/path_to_inst
Double check for missing devices
cd /devices
find . –print|cpio –pdum /mnt/devices
Replace new pseudo with original
cd /mnt/devices
mv pseudo.today pseudo
Recreate /dev entries
disks –r /mnt
devlinks –r /mnt
ports –r /mnt
tapes –r /mnt
Edit inittab
cd /mnt/etc
vi inittab – change default run level to 2
Edit vfstab
cd /mnt/etc
comment out entries for data file systems
Change root and var entries to match partitions created earlier.
Unmount root and var
cd /
umount /mnt/var
umount /mnt
Check file systems are clean
fsck /dev/dsk/c0t0d0s0
fsck /dev/dsk/c0t0d0s3
Load system from recovered root file systems.
uadmin 2 0 drop out to prom
Check devalias
printenv should show correct boot device (probably c0t0d0s0)
Recovery reboot to single user (from c0t0d0s0)
boot -rs
Note – There is a known Solaris bug whereby sometimes- but not always – solaris will change the root disk entry in /etc/vfstab. If the system will not boot ( error messages relate to a read-only root disk, and derived write errors ), boot from the cd and correct the entries in vfstab. (This does not always happen)
Note – You are now running on the recovered root file system
Set up remaining file systems
Check your current df –k listing from the source machine.
format disks
Use ‘format’ command
Create file systems.
use newfs
restore file systems
Use these commands.
Rewind the tape: mt –f /dev/rmt/0
Move tape forward to file1 mt –f /dev/rmt/0n fsf 1
Recover current tape file into current directory:
ufsrestore rvf /dev/rmt/0cbn
Rewind and offline tape: mt –f /dev/rmt/0 rewoffl
When all required file system are created and recovered,
Edit /etc/vfstab – change the disks and slices to the correct values, and uncomment the required lines,
Mount filesystems as detailed in /etc/vfstab:
mountall