Subject: Re: disklabel question (a different one this time)
To: None <port-pmax@NetBSD.ORG>
From: Reini (Reinhold Huber) <Reinhold.Huber@Fachschaften.TU-Muenchen.DE (Reinhold Huber)>
List: port-pmax
Date: 10/22/1997 14:04:23
Hi!
On Tue, 21 Oct 1997, Paul Bickford wrote:
>
> OK, I'm trying to prepare a drive on my DS3100 to install NetBSD onto, but
> I keep getting the following error:
>
> # disklabel -w -B -b rzboot -s bootrz rz1 st
> disklabel: ioctl DIOCSDINFO: Open partition would move or shrink.
> #
>
You could try:
Leave out steps 1 and 2 if there is already some crude label on your disk.
The -r flag tells disklabel to read/write directly on the disk. Please
don't forget it.
1)
disklabel -r -W rz0
(this makes the disk writeable)
2)
dd if=/dev/rrz0c of=/dev/rrz1c count=20
(this copies the disklabel from rz0 to rz1, assumed rz0 is your boot
disk and rz1 is the disk you want to label)
3)
disklabel -r -e rz1
to adjust the drive parameters. Don't touch the partition entries in
this step.
If you get an error that some partition exceeds disk size, then you need
to make the offending ones (likely c) smaller by a step similar to 5.
4)
disklabel -r rz1
to find out what the label looks like.
Look for partitions starting with offset 0, which may not be c, if your
disk is smaller than the current entry for c. The
Assumed a is beginning at 0, then do:
5)
disklabel -r -e /dev/rrz1a
and set the size of the c partition to the totlal disk size.
In the last step, do again:
6)
disklabel -r -e /dev/rrz1a
and set the other partition offsets, sizes and filesys parameters to the
values you like.
Hope this helps.
Greetings,
Reinhold Huber