DragonFly bugs List (threaded) for 2007-07
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
Re: [issue671] disklabel in raw and kernel mode disagree
:Simon 'corecode' Schubert <corecode@fs.ei.tum.de> added the comment:
:
:also happens with vn(4):
:
:# truncate -s 4G disk.img
:# vnconfig -c -s labels vn0 disk.img
:# fdisk -I /dev/vn0
:...
:# disklabel -r vn0s1
I tried that exact sequence and it worked ok. The disklabel -r vn0s1
returned the translated disklabel (partition c starting at offset 0)
instead of the on-disk disklabel. Which means that vn0s1 properly
snooped the raw read.
test28# cd /home
test28# rm disk.img
test28# truncate -s 4G disk.img
test28# vnconfig -c -s labels vn0 disk.img
test28# fdisk -I /dev/vn0
******* Working on device /dev/vn0 *******
fdisk: invalid fdisk partition table found
Warning: ending cylinder wraps, using all 1's
test28#
test28# fdisk vn0
******* Working on device /dev/vn0 *******
parameters extracted from device are:
cylinders=4096 heads=64 sectors/track=32 (2048 blks/cyl)
Figures below won't work with BIOS for partitions not in cyl 1
parameters to be used for BIOS calculations are:
cylinders=4096 heads=64 sectors/track=32 (2048 blks/cyl)
Media sector size is 512
Warning: BIOS sector numbering starts with sector 1
Information from DOS bootblock is:
The data for partition 1 is:
sysid 165,(DragonFly/FreeBSD/NetBSD/386BSD)
start 32, size 8388576 (4095 Meg), flag 80 (active)
beg: cyl 0/ head 1/ sector 1;
end: cyl 1023/ head 255/ sector 63
The data for partition 2 is:
<UNUSED>
The data for partition 3 is:
<UNUSED>
The data for partition 4 is:
<UNUSED>
test28#
test28# disklabel -r -w vn0s1 auto
test28# disklabel -r vn0s1
...
16 partitions:
# size offset fstype
c: 8388576 0 unused # 4095.984M
-Matt
Matthew Dillon
<dillon@backplane.com>
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]