Bug 196318 - [msdosfs] can't mount 4096 byte sector MSDOS formatted drive
Summary: [msdosfs] can't mount 4096 byte sector MSDOS formatted drive
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-fs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-12-28 04:50 UTC by Adrian Chadd
Modified: 2017-10-13 17:47 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Adrian Chadd freebsd_committer freebsd_triage 2014-12-28 04:50:29 UTC
It seems I can't mount 4k sector size msdos disks.

I don't know if the underlying FS is 4k or 512 byte sectors; I just know that this USB enclosure works fine on Linux, Windows and MacOS X.

However, under FreeBSD:

usb_alloc_device: set address 2 failed (USB_ERR_IOERROR, ignored)
usbd_setup_device_desc: getting device descriptor at addr 2 failed, USB_ERR_IOERROR
usbd_req_re_enumerate: addr=2, set address failed! (USB_ERR_IOERROR, ignored)
usbd_setup_device_desc: getting device descriptor at addr 2 failed, USB_ERR_IOERROR
ugen4.2: <iomega> at usbus4
umass0: <Mass Storage Class Interface> on usbus4
umass0:  SCSI over Bulk-Only; quirks = 0x0000
umass0:2:0: Attached to scbus2
da0 at umass-sim0 bus 0 scbus2 target 0 lun 0
da0: <OEM Ext Hard Disk 0000> Fixed Direct Access SCSI-5 device 
da0: Serial Number 0000D20313BC
da0: 1.000MB/s transfers
da0: 476240MB (121917446 4096 byte sectors: 255H 63S/T 7589C)
da0: quirks=0x2<NO_6_BYTE>
cd1 at umass-sim0 bus 0 scbus2 target 0 lun 1
cd1: <Virtual CDROM > Fixed CD-ROM SCSI-0 device 
cd1: 1.000MB/s transfers
cd1: cd present [358400 x 2048 byte records]
cd1: quirks=0x10<10_BYTE_ONLY>
root@lucy-11i386:~ # 

.. then:

root@lucy-11i386:~ # fdisk da0
fdisk: could not detect sector size
root@lucy-11i386:~ # gpart list da0
Geom name: da0
modified: false
state: OK
fwheads: 255
fwsectors: 63
last: 121917445
first: 1
entries: 4
scheme: MBR
Providers:
1. Name: da0s1
   Mediasize: 499373850624 (465G)
   Sectorsize: 4096
   Stripesize: 0
   Stripeoffset: 8192
   Mode: r0w0e0
   rawtype: 11
   length: 499373850624
   offset: 8192
   type: fat32
   index: 1
   end: 121917445
   start: 2
Consumers:
1. Name: da0
   Mediasize: 499373858816 (465G)
   Sectorsize: 4096
   Mode: r0w0e0

.. so:

root@lucy-11i386:~ # mount -t msdosfs -o large /dev/da0s1 /mnt
mount_msdosfs: /dev/da0s1: Invalid argument

This is on:

adrian@lucy-11i386:~/work/freebsd/head/src/sys/fs/msdosfs % uname -a
FreeBSD lucy-11i386 11.0-CURRENT FreeBSD 11.0-CURRENT #0 r276053M: Mon Dec 22 00:44:47 PST 2014     adrian@lucy-11i386:/usr/home/adrian/work/freebsd/head/obj/usr/home/adrian/work/freebsd/head/src/sys/LUCY_11_i386  i386