Re: unknown USR mass storage device

From: Polytropon <freebsd_at_edvax.de>
Date: Tue, 27 Dec 2022 06:05:47 UTC
On Mon, 26 Dec 2022 10:57:12 -0500, Robert Huff wrote:
> 
> Hello:
> 	On a system running:
> 
> FreeBSD 14.0-CURRENT #0 main-f0a15aafcb
> Mon Oct 31 08:19:54 EDT 2022
> amd64
> 
> 	I plugged a mystery thumb drive into a USB port, and went through
> the usual steps of trying to mount it.
> 	Except the drive isn't recognized by gpart.  Or camcontrol.
> 	/var/log/messages shows:
> 
> Dec 26 10:48:38 jerusalem kernel: usb_msc_auto_quirk: UQ_MSC_NO_GETMAXLUN set for USB mass storage device Generic Mass Storage Device (0x14cd:0x1212)
> Dec 26 10:48:38 jerusalem kernel: usb_msc_auto_quirk: UQ_MSC_NO_TEST_UNIT_READY set for USB mass storage device Generic Mass Storage Device (0x14cd:0x1212)
> Dec 26 10:48:38 jerusalem kernel: usb_msc_auto_quirk: UQ_MSC_NO_PREVENT_ALLOW set for USB mass storage device Generic Mass Storage Device (0x14cd:0x1212)
> Dec 26 10:48:38 jerusalem kernel: usb_msc_auto_quirk: UQ_MSC_NO_SYNC_CACHE set for USB mass storage device Generic Mass Storage Device (0x14cd:0x1212)
> Dec 26 10:48:38 jerusalem kernel: ugen2.4: <Generic Mass Storage Device> at usbus2
> Dec 26 10:48:38 jerusalem kernel: umass0 on uhub7
> Dec 26 10:48:38 jerusalem kernel: umass0: <Generic Mass Storage Device, class 0/0, rev 2.00/1.00, addr 4> on usbus2
> Dec 26 10:48:38 jerusalem kernel: umass0:  SCSI over Bulk-Only; quirks = 0xc101
> Dec 26 10:48:38 jerusalem kernel: umass0:6:0: Attached to scbus6
> Dec 26 10:48:39 jerusalem kernel: da0 at umass-sim0 bus 0 scbus6 target 0 lun 0
> Dec 26 10:48:39 jerusalem kernel: da0: <Mass Storage Device 1.00> Removable Direct Access SCSI device
> Dec 26 10:48:39 jerusalem kernel: da0: Serial Number 121220160204
> Dec 26 10:48:39 jerusalem kernel: da0: 40.000MB/s transfers
> Dec 26 10:48:39 jerusalem kernel: da0: Attempt to query device size failed: NOT READY, Medium not present
> Dec 26 10:48:39 jerusalem kernel: da0: quirks=0x2<NO_6_BYTE>
> Dec 26 10:48:39 jerusalem kernel: da0: Write Protected
> 
> 	<insert slack-jawed expression>
> 	Anyone know what I'm looking at here?

What capabilities does usbconfig list für this particular
device? Without knowing what it is, I'm just guessing: It
could be a device that contains drivers for "Windows",
presented on an imaginary file system (USB mass storage,
write protected). Some older UMTS sticks did this, but
they presented themselves both as USB CD drive and as
USB communications device. Maybe you're looking at
something comparable?

If you cannot use gpart, can you inspect the raw file
(/dev/da0, maybe /dev/da0s1), "file -s /dev/da0" or
using a hex viewer, if you can access data on the
device at all, without mounting?

Also check the USB vendor and device ID, maybe you can
find out what it is?

If you're sure it is a regular USB stick / thumb drive,
try "newfs /dev/da0". Before you do, replace the write
ring. ;-)




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...