How do I control number of volumes automounted?

Asked by Emmet Hikory

    When I connect my Zaurus 3100 (stock kernel) to my workstation, and it is configured to behave as a USB device, gnome-mount loads seven windows, labeled "disk1" to "disk7" in Nautilus. They all have exactly the same content, and all must be unmounted to safely disconnect the Zaurus. I'd prefer to only have one mount, and one unmount. I don't have this problem with Windows XP, Windows Vista, or MacOS X. I haven't tried other Linux distributions.

    How could I configure my system to only mount once? Is this a problem with the Zaurus, or with something in Ubuntu?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Cesare Tirabassi
Solved:
Last query:
Last reply:
Revision history for this message
Launchpad Janitor (janitor) said :
#1

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Emmet Hikory (persia) said :
#2

Could anyone please suggest how I could look for the cause of the issue?

Revision history for this message
Markus Thielmann (thielmann) said :
#3

Thanks for your question.

What version of Ubuntu do you use? Is it a newly installed or updated version?

To be honest, I've never heard of such a problem, nor do I find any problems in the forums or the bug tracker. So it might be a good idea to update to Ubuntu Feisty, if not already installed.

Revision history for this message
Emmet Hikory (persia) said :
#4

I've encountered this problem with Ubuntu Edgy, Feisty, and Gutsy with a continuously updated devlopment system. I'm more than happy to trace the issue, but I don't know which is the relevant application stack betwen udev and nautilus, where I might active debugging, nor which logs should be investigated to track it down.

If there's not a simple answer to the question, which given the prevalence of the hardware may not be surprising, I'd be just as happy with a pointer to succinct documentation on how the USB hotplug event turns into new windows on my desktop.

Revision history for this message
Smith (andrey-laptev) said :
#5

Greetings,
I'm very interested in this problem solution. Ubuntu Feisty is installed and Zaurus 3200 is tried to be plugged. The result is 8 points to be mounted.

root@smith-desktop:/sys/bus/scsi/devices/2:0:0:0# ls -al /dev/disk/by-id
итого 0
drwxr-xr-x 2 root root 340 2007-05-24 20:59 .
drwxr-xr-x 6 root root 120 2007-05-25 00:09 ..
lrwxrwxrwx 1 root root 9 2007-05-25 00:09 scsi-1ATA_HDS725050KLA360_KRVN0AZBGPV12J -> ../../sda
lrwxrwxrwx 1 root root 10 2007-05-25 00:09 scsi-1ATA_HDS725050KLA360_KRVN0AZBGPV12J-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 2007-05-25 00:09 scsi-1ATA_HDS725050KLA360_KRVN0AZBGPV12J-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 2007-05-25 00:09 scsi-1ATA_HDS725050KLA360_KRVN0AZBGPV12J-part5 -> ../../sda5
lrwxrwxrwx 1 root root 10 2007-05-25 00:09 scsi-1ATA_HDS725050KLA360_KRVN0AZBGPV12J-part6 -> ../../sda6
lrwxrwxrwx 1 root root 10 2007-05-25 00:09 scsi-1ATA_HDS725050KLA360_KRVN0AZBGPV12J-part7 -> ../../sda7
lrwxrwxrwx 1 root root 10 2007-05-25 00:09 scsi-1ATA_HDS725050KLA360_KRVN0AZBGPV12J-part8 -> ../../sda8
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:0 -> ../../sdb
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:1 -> ../../sdc
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:2 -> ../../sdd
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:3 -> ../../sde
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:4 -> ../../sdf
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:5 -> ../../sdg
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:6 -> ../../sdh
lrwxrwxrwx 1 root root 9 2007-05-24 20:59 usb-Sharp_SL-C3200-0:7 -> ../../sdi

Hope for reply
Thank you in advance

Revision history for this message
Emmet Hikory (persia) said :
#6

Thanks for providing the listing. That's exactly the problem I was having. I'm really glad to hear it's not just me. We can hope that someone proides guidance on determining if this is a Ubuntu or Zaurus problem, and perhaps share a workaround that allows the extra spurious devices to be blocked in some way, if the problem is determined to be on the Zaurus.

Revision history for this message
Launchpad Janitor (janitor) said :
#7

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Emmet Hikory (persia) said :
#8

It's nice that questions expire without activity, but it would be preferable if there was activity :)

Revision history for this message
Launchpad Janitor (janitor) said :
#9

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Emmet Hikory (persia) said :
#10

Is there another forum where I should be posting this to garner support?

Revision history for this message
Launchpad Janitor (janitor) said :
#11

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Emmet Hikory (persia) said :
#12

That's OK. It's still not answered, and I'm still prepared to help solve it.

Revision history for this message
Cesare Tirabassi (norsetto) said :
#13

First of all, we should check what the kernel see. Can you check what is logged when you plug in your PDA?
You can use for instance:

dmesg | tail -n20

Mind you, these posts are not very encouraging:

http://www.tyrannozaurus.com/?q=node/959
http://www.oesf.org/forums/index.php?s=dceb57a4a4be84a87091fbbd314ca2c8&showtopic=18974&hl=
http://www.oesf.org/forums/index.php?s=dceb57a4a4be84a87091fbbd314ca2c8&showtopic=14664&hl=

Revision history for this message
Emmet Hikory (persia) said :
#14

Thanks for helping with this! There's lots of dups on the net, but I think with a little investigation it can be solved.

Here is the relevant dmesg output (which is 1) more than 20 lines, and 2) demonstrates that the problem is either in the Ubuntu kernel or the Zaurus kernel).

[21339.802366] usb 2-3: new full speed USB device using ohci_hcd and address 84
[21342.186049] usb 2-3: configuration #1 chosen from 1 choice
[21342.188770] scsi6 : SCSI emulation for USB Mass Storage devices
[21342.188819] usb-storage: device found at 84
[21342.188820] usb-storage: waiting for device to settle before scanning
[21344.462470] usb-storage: device scan complete
[21344.465691] scsi 6:0:0:0: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.468844] scsi 6:0:0:1: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.472004] scsi 6:0:0:2: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.475183] scsi 6:0:0:3: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.478363] scsi 6:0:0:4: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.481544] scsi 6:0:0:5: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.484727] scsi 6:0:0:6: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.487907] scsi 6:0:0:7: Direct-Access Sharp SL-C3100 1.00 PQ: 0 ANSI: 0 CCS
[21344.497902] sd 6:0:0:0: [sde] 7959168 512-byte hardware sectors (4075 MB)
[21344.501083] sd 6:0:0:0: [sde] Write Protect is off
[21344.501086] sd 6:0:0:0: [sde] Mode Sense: 43 00 00 00
[21344.501088] sd 6:0:0:0: [sde] Assuming drive cache: write through
[21344.512900] sd 6:0:0:0: [sde] 7959168 512-byte hardware sectors (4075 MB)
[21344.516079] sd 6:0:0:0: [sde] Write Protect is off
[21344.516082] sd 6:0:0:0: [sde] Mode Sense: 43 00 00 00
[21344.516084] sd 6:0:0:0: [sde] Assuming drive cache: write through
[21344.516087] sde:
[21344.638843] sd 6:0:0:0: [sde] Attached SCSI removable disk
[21344.638881] sd 6:0:0:0: Attached scsi generic sg4 type 0
[21344.644055] sd 6:0:0:1: [sdf] 7959168 512-byte hardware sectors (4075 MB)
[21344.647075] sd 6:0:0:1: [sdf] Write Protect is off
[21344.647079] sd 6:0:0:1: [sdf] Mode Sense: 43 00 00 00
[21344.647083] sd 6:0:0:1: [sdf] Assuming drive cache: write through
[21344.658791] sd 6:0:0:1: [sdf] 7959168 512-byte hardware sectors (4075 MB)
[21344.661972] sd 6:0:0:1: [sdf] Write Protect is off
[21344.661975] sd 6:0:0:1: [sdf] Mode Sense: 43 00 00 00
[21344.661977] sd 6:0:0:1: [sdf] Assuming drive cache: write through
[21344.661980] sdf:
[21344.667013] sd 6:0:0:1: [sdf] Attached SCSI removable disk
[21344.667050] sd 6:0:0:1: Attached scsi generic sg5 type 0
[21344.671971] sd 6:0:0:2: [sdg] 7959168 512-byte hardware sectors (4075 MB)
[21344.675612] sd 6:0:0:2: [sdg] Write Protect is off
[21344.675616] sd 6:0:0:2: [sdg] Mode Sense: 43 00 00 00
[21344.675618] sd 6:0:0:2: [sdg] Assuming drive cache: write through
[21344.687194] sd 6:0:0:2: [sdg] 7959168 512-byte hardware sectors (4075 MB)
[21344.690609] sd 6:0:0:2: [sdg] Write Protect is off
[21344.690614] sd 6:0:0:2: [sdg] Mode Sense: 43 00 00 00
[21344.690617] sd 6:0:0:2: [sdg] Assuming drive cache: write through
[21344.690620] sdg:
[21344.696119] sd 6:0:0:2: [sdg] Attached SCSI removable disk
[21344.696160] sd 6:0:0:2: Attached scsi generic sg6 type 0
[21344.701018] sd 6:0:0:3: [sdh] 7959168 512-byte hardware sectors (4075 MB)
[21344.704058] sd 6:0:0:3: [sdh] Write Protect is off
[21344.704064] sd 6:0:0:3: [sdh] Mode Sense: 43 00 00 00
[21344.704067] sd 6:0:0:3: [sdh] Assuming drive cache: write through
[21344.739688] sd 6:0:0:3: [sdh] 7959168 512-byte hardware sectors (4075 MB)
[21344.742868] sd 6:0:0:3: [sdh] Write Protect is off
[21344.742871] sd 6:0:0:3: [sdh] Mode Sense: 43 00 00 00
[21344.742873] sd 6:0:0:3: [sdh] Assuming drive cache: write through
[21344.742877] sdh:
[21344.748159] sd 6:0:0:3: [sdh] Attached SCSI removable disk
[21344.748200] sd 6:0:0:3: Attached scsi generic sg7 type 0
[21344.753135] sd 6:0:0:4: [sdi] 7959168 512-byte hardware sectors (4075 MB)
[21344.756283] sd 6:0:0:4: [sdi] Write Protect is off
[21344.756287] sd 6:0:0:4: [sdi] Mode Sense: 43 00 00 00
[21344.756289] sd 6:0:0:4: [sdi] Assuming drive cache: write through
[21344.768327] sd 6:0:0:4: [sdi] 7959168 512-byte hardware sectors (4075 MB)
[21344.771309] sd 6:0:0:4: [sdi] Write Protect is off
[21344.771313] sd 6:0:0:4: [sdi] Mode Sense: 43 00 00 00
[21344.771315] sd 6:0:0:4: [sdi] Assuming drive cache: write through
[21344.771319] sdi:
[21344.776337] sd 6:0:0:4: [sdi] Attached SCSI removable disk
[21344.776380] sd 6:0:0:4: Attached scsi generic sg8 type 0
[21344.781508] sd 6:0:0:5: [sdj] 7959168 512-byte hardware sectors (4075 MB)
[21344.784260] sd 6:0:0:5: [sdj] Write Protect is off
[21344.784264] sd 6:0:0:5: [sdj] Mode Sense: 43 00 00 00
[21344.784266] sd 6:0:0:5: [sdj] Assuming drive cache: write through
[21344.796277] sd 6:0:0:5: [sdj] 7959168 512-byte hardware sectors (4075 MB)
[21344.799687] sd 6:0:0:5: [sdj] Write Protect is off
[21344.799691] sd 6:0:0:5: [sdj] Mode Sense: 43 00 00 00
[21344.799693] sd 6:0:0:5: [sdj] Assuming drive cache: write through
[21344.799697] sdj:
[21344.805201] sd 6:0:0:5: [sdj] Attached SCSI removable disk
[21344.805248] sd 6:0:0:5: Attached scsi generic sg9 type 0
[21344.810135] sd 6:0:0:6: [sdk] 7959168 512-byte hardware sectors (4075 MB)
[21344.813128] sd 6:0:0:6: [sdk] Write Protect is off
[21344.813132] sd 6:0:0:6: [sdk] Mode Sense: 43 00 00 00
[21344.813134] sd 6:0:0:6: [sdk] Assuming drive cache: write through
[21344.824927] sd 6:0:0:6: [sdk] 7959168 512-byte hardware sectors (4075 MB)
[21344.828314] sd 6:0:0:6: [sdk] Write Protect is off
[21344.828319] sd 6:0:0:6: [sdk] Mode Sense: 43 00 00 00
[21344.828321] sd 6:0:0:6: [sdk] Assuming drive cache: write through
[21344.828325] sdk:
[21344.833814] sd 6:0:0:6: [sdk] Attached SCSI removable disk
[21344.833860] sd 6:0:0:6: Attached scsi generic sg10 type 0
[21344.838487] sd 6:0:0:7: [sdl] 7959168 512-byte hardware sectors (4075 MB)
[21344.841719] sd 6:0:0:7: [sdl] Write Protect is off
[21344.841722] sd 6:0:0:7: [sdl] Mode Sense: 43 00 00 00
[21344.841725] sd 6:0:0:7: [sdl] Assuming drive cache: write through
[21344.853766] sd 6:0:0:7: [sdl] 7959168 512-byte hardware sectors (4075 MB)
[21344.856557] sd 6:0:0:7: [sdl] Write Protect is off
[21344.856560] sd 6:0:0:7: [sdl] Mode Sense: 43 00 00 00
[21344.856562] sd 6:0:0:7: [sdl] Assuming drive cache: write through
[21344.856566] sdl:
[21344.861771] sd 6:0:0:7: [sdl] Attached SCSI removable disk
[21344.861813] sd 6:0:0:7: Attached scsi generic sg11 type 0

    At this point, I'm not sure how to trace the USB communication to determine whether the error lies with the Zaurus or the Ubuntu kernel. It did work fine in Dapper (with my Zaurus 860), so I'm suspecting an Ubuntu issue, although I'm unsure.

Revision history for this message
Cesare Tirabassi (norsetto) said :
#15

Can you check if the zaurus module is loaded by the kernel?
lsmod | grep zaurus should report something like (just an example):

Module Size Used by
zaurus 7552 0
cdc_ether 8704 1 zaurus
usbnet 22280 2 zaurus, cdc_ether

Revision history for this message
Cesare Tirabassi (norsetto) said :
#16

Check also what is the output of:

sudo lsusb -v -d 04dd:

Revision history for this message
Emmet Hikory (persia) said :
#17

Frustratingly, with current gutsy, Nautilus appears to want to read everything on the device, and hangs for about 10 minutes during the mount. I suspect this will be fixed as we get closer to release, so I'm not worried about it now, but it makes things a little slower than they might be...

Anyway, debug output:
1) lsmod | grep zaurus returns nothing
2) modinfo zaurus returns "modinfo: could not find module zaurus"
3) uname -a returns "Linux frigga 2.6.22-7-generic #1 SMP Mon Jun 25 17:07:55 GMT 2007 x86_64 GNU/Linux" (as otherwise it may be difficult to determine which kernel needs a look
4) sudo lsusb -v -d 04dd: returns all of:

Bus 002 Device 030: ID 04dd:9050 Sharp Corp. Zaurus C-860 PDA
Device Descriptor:
  bLength 18
  bDescriptorType 1
  bcdUSB 2.00
  bDeviceClass 0 (Defined at Interface level)
  bDeviceSubClass 0
  bDeviceProtocol 0
  bMaxPacketSize0 16
  idVendor 0x04dd Sharp Corp.
  idProduct 0x9050 Zaurus C-860 PDA
  bcdDevice 0.00
  iManufacturer 1 Sharp
  iProduct 2 SL-C3100
  iSerial 0
  bNumConfigurations 1
  Configuration Descriptor:
    bLength 9
    bDescriptorType 2
    wTotalLength 39
    bNumInterfaces 1
    bConfigurationValue 1
    iConfiguration 3 Mass Storage Configuration
    bmAttributes 0xc0
      Self Powered
    MaxPower 2mA
    Interface Descriptor:
      bLength 9
      bDescriptorType 4
      bInterfaceNumber 0
      bAlternateSetting 0
      bNumEndpoints 3
      bInterfaceClass 8 Mass Storage
      bInterfaceSubClass 6 SCSI
      bInterfaceProtocol 80 Bulk (Zip)
      iInterface 4 Mass Storage Interface
      Endpoint Descriptor:
        bLength 7
        bDescriptorType 5
        bEndpointAddress 0x02 EP 2 OUT
        bmAttributes 2
          Transfer Type Bulk
          Synch Type None
          Usage Type Data
        wMaxPacketSize 0x0040 1x 64 bytes
        bInterval 0
      Endpoint Descriptor:
        bLength 7
        bDescriptorType 5
        bEndpointAddress 0x81 EP 1 IN
        bmAttributes 2
          Transfer Type Bulk
          Synch Type None
          Usage Type Data
        wMaxPacketSize 0x0040 1x 64 bytes
        bInterval 0
      Endpoint Descriptor:
        bLength 7
        bDescriptorType 5
        bEndpointAddress 0x85 EP 5 IN
        bmAttributes 3
          Transfer Type Interrupt
          Synch Type None
          Usage Type Data
        wMaxPacketSize 0x0008 1x 8 bytes
        bInterval 10
can't get debug descriptor: Connection timed out
Device Status: 0x0001
  Self Powered

Revision history for this message
Best Cesare Tirabassi (norsetto) said :
#18

Yes, apparently the module is not configured in Gutsy:

# CONFIG_USB_NET_ZAURUS is not set

While it is in Feisty:

CONFIG_USB_NET_ZAURUS=m

Indeed:

cesare@desktop:~$ modinfo zaurus
filename: /lib/modules/2.6.20-16-lowlatency/kernel/drivers/usb/net/zaurus.ko
license: GPL
description: Sharp Zaurus PDA, and compatible products
author: Pavel Machek, David Brownell
srcversion: 170F62592AA962745B3ECD9
alias: usb:v07B4p0F02d*dc*dsc*dp*ic02isc06ip00*
alias: usb:v*p*d*dc*dsc*dp*ic02isc0Aip00*
alias: usb:v04DDp9050d*dc*dsc*dp*ic02isc06ip00*
alias: usb:v04DDp9032d*dc*dsc*dp*ic02isc06ip00*
alias: usb:v04DDp9031d*dc*dsc*dp*ic02isc06ip00*
alias: usb:v04DDp8007d*dc*dsc*dp*ic02isc06ip00*
alias: usb:v04DDp8006d*dc*dsc*dp*ic02isc06ip00*
alias: usb:v04DDp8005d*dc*dsc*dp*ic02isc06ip00*
alias: usb:v04DDp8004d*dc*dsc*dp*ic02isc06ip00*
depends: cdc_ether,usbnet,usbcore
vermagic: 2.6.20-16-lowlatency SMP preempt mod_unload

In any case, I don't think this is the problem, as zaurus.c is simply to be able to use usbnet (which I don't think is involved in this).

I found it strange that your model was recognised as a C-860 PDA but indeed this is the case (this is just an example from zaurus.c):

/* reported with some C860 units */
idProduct = 0x9050, /* C-860 */

I will check next what lsusb reports.

Revision history for this message
Emmet Hikory (persia) said :
#19

Thanks Cesare Tirabassi, that solved my question.

Revision history for this message
Emmet Hikory (persia) said :
#20

Thanks for the investigation. Given the information requested, and the pointers, I'm certain that this is either a bug in the Ubuntu (and likely upstream) kernel, and that the rest of the software stack is doing the right thing. I'll investigate some more, and open a bug once I have sufficient detail for proper analysis.