Uwe Dippel wrote:
> [And I did read FAQ Chapter 14 forth and back]
> 
> I have a working install on sd0. There are plenty of data on separate
> partitions on sd0 that I don't need, but it's a good install. Therefore
> I'd like to transfer the system only to sd1. 
> dd if=/dev/rsd0c of=/dev/rsd1c transfers the whole disc. Which will take
> days; plus sd1 is smaller than sd0.
> So I formatted sd1 (fdisk/disklabel) as I want to have the system, with 
> the same system partitions (fstab) as on sd0; except without the extra 
> data partitions. With dump / restore I copied the system partitions to sd1. 
> Of course, it didn't boot. So I tried
> dd if=/dev/rsd0c of=/home/mbr bs=512 count=1 and writing mbr similarly to
> sd1; but that didn't bring the proper results (maybe too linux-ish ?). mbr
> has the expected 512 Byte, btw.

That got your fdisk partitions copied over.  However, you just tried to
make your little disk the same size as your big disk.  You want to clean
that up. :)

> I'm sure someone has done this: How do I transfer a system to another
> drive; including fdisk and disklabel; excluding some unwanted non-system
> partitions ?

The tidbit you are missing is /boot is "position dependent".  Its
location (inode) is hard-coded in the PBR, so if you copy all the files
from sd0 to sd1, you will have moved it, and the PBR will end up loading
something other than /boot.

Solutions:
1) dd your /dev/rsd0a partition to /dev/rsd1a.  This way, you get the
PBR and the /boot file to continue to work together.

2) AFTER you copy everything over, reinstall the PBR, using installboot(8).

Look again at FAQ 14.6 and 14.8, hopefully they make more sense now. :)
Also note that in 14.9, a complete restore requires the installboot step
(even if you had a good PBR in place before, after restoring /boot, you
may have invalidated the old PBR).

> 
> Adding another question:
> man restore says:
> # newfs /dev/rrp0g eagle
> # mount /dev/rp0g /mnt
> # cd /mnt
> # restore rf /dev/rst8
> I don't understand 'eagle'; man newfs didn't give me much of a clue.

yikes.  No idea.  I'm also trying to figure out the rp(4) device, too.

Nick.

Reply via email to