mounting fake cd-roms that are on usb sticks (maybe a U3 stick)

Peter F. Patel-Schneider pfpschneider at gmail.com
Fri Oct 23 01:21:43 CEST 2015


This may indeed be a U3 stick.  It shows up as two devices (CD and regular
disk) which now appears to me as how these things show up.

However Linux appears to be handling it fine, i.e., creating /dev/sr0 for the
CD part, and this part can be mounted manually.

However, XFCE doesn't recognize the CD part even though it handles CDs fine.

Does anyone know what might be going wrong?  What part of XFCE desktop and
Thunar is responsible for determining which OS events correspond to block
devices that should show up on the desktop or in Thunar?  Is there a way to
turn on logging of device handling in XFCE, ideally without having to compile
my own version?

Note that I don't want to blow away the CD part as that has the data I am
interested in seeing when the stick is inserted.

peter

PS:  I took a look at the detailed udev events and everything appears to be
the same between the CD partition and a regular partition.

On 10/21/2015 03:52 AM, Peter F. Patel-Schneider wrote:
> My initial guess was indeed that this was a U3 disk (or something similar).
> However, that does not appear to be the case, as can be seen from the kernel
> messages.  The disk has two partitions - a normal one (5:0:0:1) that is
> mounted fine and one (5:0:0:0) that claims to be a CD-ROM and does not show up
> on the desktop.  This CD-ROM partition does result in the creation of /dev/sr0
> which can then be mounted manually.
> 
> My guess is that there is no way to signal that a CD is present in /dev/sr0 so
> there is nothing to trigger mounting, but this is only a guess.
> 
> peter
> 
> 
> On 10/21/2015 03:06 AM, Darac Marjal wrote:
>> On Tue, Oct 20, 2015 at 09:01:56AM -0700, Peter F. Patel-Schneider wrote:
>>> I have USB stick that presents as both a CD-ROM drive and a regular drive.
>>> (Why?  I guess so that the CD-ROM part cannot be modified.)
>>
>> Is this a "U3" drive, by any chance? There, the CD-ROM part contains 
>> drivers/installers for the functionality on the HDD part. The idea was 
>> that the host OS (the designers only thought to target Windows) would 
>> see the CD-ROM and an "empty" hard drive, install a launcher application 
>> from the CD-ROM and that installer would provide access to apps on the 
>> disk.
>>
>> You can modify a U3 disk (change the CD-image, remove the CD part and so 
>> on) with U3-tool: http://u3-tool.sourceforge.net/
>>
>>>
>>> The regular drive is detected, shows up on the desktop, and is mounted fine.
>>> However, the CD-ROM part does not even show up on the desktop and the only way
>>> I can figure out to mount it is `sudo mount /dev/sr0 /mnt`.
>>>
>>> I would like to have this drive to at least show up on the desktop, and
>>> preferably be automounted.  Does anyone know how to do this?
>>>
>>> peter
>>>
>>> PS:  Here is an edited system log of what happens when the stick is plugged in.
>>>
>>> kernel: usb 1-1: new high-speed USB device number 20 using xhci_hcd
>>> kernel: usb 1-1: New USB device found, idVendor=058f, idProduct=6387
>>> kernel: usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
>>> kernel: usb 1-1: Product: Mass Storage
>>> kernel: usb 1-1: Manufacturer: Generic
>>> kernel: usb 1-1: SerialNumber: B763F0E4
>>> kernel: usb-storage 1-1:1.0: USB Mass Storage device detected
>>> kernel: scsi host5: usb-storage 1-1:1.0
>>> mtp-probe[3142]: checking bus 1, device 20:
>>> "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-1"
>>> mtp-probe[3142]: bus: 1, device: 20 was not an MTP device
>>> kernel: scsi 5:0:0:0: CD-ROM            Generic  Autorun Disk     8.00 PQ: 0
>>> ANSI: 4
>>> kernel: scsi 5:0:0:1: Direct-Access     Generic  Flash Disk       8.01 PQ: 0
>>> ANSI: 4
>>> kernel: sr 5:0:0:0: [sr0] scsi3-mmc drive: 52x/52x cd/rw xa/form2 tray
>>> kernel: sr 5:0:0:0: Attached scsi CD-ROM sr0
>>> kernel: sr 5:0:0:0: Attached scsi generic sg2 type 5
>>> kernel: sd 5:0:0:1: Attached scsi generic sg3 type 0
>>> kernel: sd 5:0:0:1: [sdc] 3639996 512-byte logical blocks: (1.86 GB/1.73 GiB)
>>> kernel: sd 5:0:0:1: [sdc] Write Protect is off
>>> kernel: sd 5:0:0:1: [sdc] Mode Sense: 23 00 00 00
>>> kernel: sd 5:0:0:1: [sdc] Write cache: disabled, read cache: enabled, doesn't
>>> support DPO or FUA
>>> kernel:  sdc: sdc1
>>> kernel: sd 5:0:0:1: [sdc] Attached SCSI removable disk
>>> _______________________________________________
>>> Xfce mailing list
>>> Xfce at xfce.org
>>> https://mail.xfce.org/mailman/listinfo/xfce
>>> http://www.xfce.org
>>
>>
>>
>> _______________________________________________
>> Xfce mailing list
>> Xfce at xfce.org
>> https://mail.xfce.org/mailman/listinfo/xfce
>> http://www.xfce.org
>>


More information about the Xfce mailing list