Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

MSDOS vs diskabel regression in -4, -5 and -current



I've been asked to try to get an Olympus camera working again after an upgrade to NetBSD 4.0_STABLE. On NetBSD 3.1, the fictitious disklabel correctly has an MSDOS partition as partition e (and thus can be easily mounted with mount_msdos /dev/sd0e /mnt). On NetBSD 4.0 and later, the fdisk partition table appears subtly different and no MSDOS partition is seen in disklabel; rather there is a 4.2BSD partition as partition a.

I've a copy of the full filesystem which also exbihits the problem using vnd.

NetBSD 3.1:
netmanager 1# fdisk sd0
Disk: /dev/rsd0d
NetBSD disklabel disk geometry:
cylinders: 6, heads: 64, sectors/track: 32 (2048 sectors/cylinder)
total sectors: 14175

BIOS disk geometry:
cylinders: 6, heads: 64, sectors/track: 32 (2048 sectors/cylinder)
total sectors: 14175

Partition table:
0: Primary DOS with 12 bit FAT (sysid 1)
    start 1, size 14175 (7 MB, Cyls 0/0/2-6/59/1), Active
1: <UNUSED>
2: <UNUSED>
3: <UNUSED>
netmanager 2# disklabel sd0
# /dev/rsd0d:
type: SCSI
disk: mydisk
label: fictitious
flags:
bytes/sector: 512
sectors/track: 32
tracks/cylinder: 64
sectors/cylinder: 2048
cylinders: 6
total sectors: 14175
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0           # microseconds
track-to-track seek: 0  # microseconds
drivedata: 0

5 partitions:
#        size    offset     fstype [fsize bsize cpg/sgs]
 d:     14175         0     unused      0     0        # (Cyl.      0 -      6*)
 e:     14175         1      MSDOS                     # (Cyl.      0*-      6+)
disklabel: boot block size 0
disklabel: super block size 0
disklabel: partition e: partition extends past end of unit

NetBSD 4.0:
# dmesg | grep ^sd0
sd0 at scsibus0 target 0 lun 0: <OLYMPUS, FE210/X775, 1.00> disk removable
sd0: fabricating a geometry
sd0: 7087 KB, 6 cyl, 64 head, 32 sec, 512 bytes/sect x 14175 sectors
sd0: fabricating a geometry
sd0: mbr partition exceeds disk size
# fdisk sd0
fdisk: Cannot determine the number of heads
Disk: /dev/rsd0d
NetBSD disklabel disk geometry:
cylinders: 6, heads: 64, sectors/track: 32 (2048 sectors/cylinder)
total sectors: 14175

BIOS disk geometry:
cylinders: 6, heads: 64, sectors/track: 32 (2048 sectors/cylinder)
total sectors: 14175

Partition table:
0: Primary DOS with 12 bit FAT (sysid 1)
    start 1, size 14175 (7 MB, Cyls 0/0/2-6/58/32), Active
1: <UNUSED>
2: <UNUSED>
3: <UNUSED>
# disklabel sd0
# /dev/rsd0d:
type: SCSI
disk: FE210/X775
label: fictitious
flags: removable
bytes/sector: 512
sectors/track: 32
tracks/cylinder: 64
sectors/cylinder: 2048
cylinders: 6
total sectors: 14175
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0           # microseconds
track-to-track seek: 0  # microseconds
drivedata: 0

4 partitions:
#        size    offset     fstype [fsize bsize cpg/sgs]
 a:     14175         0     4.2BSD      0     0     0  # (Cyl.      0 -      6*)
 d:     14175         0     unused      0     0        # (Cyl.      0 -      6*)
disklabel: boot block size 0
disklabel: super block size 0

--
Stephen



Home | Main Index | Thread Index | Old Index