Automount usb-stick doesnt work

Bug #31341 reported by Owdy
2
Affects Status Importance Assigned to Milestone
Ubuntu
Invalid
Medium
Unassigned
hal (Ubuntu)
Invalid
Medium
Martin Pitt

Bug Description

USB-stick automount fails

If i put my Kingston DataTraveler 2.0 in usb port, icon appears under computer:/// in Nautilus, but when i click it, it gives an error. It isnt mounted.

http://www.ubuntuforums.org/attachment.php?attachmentid=6086&d=1139769767

Owdy (osku)
summary: + USB-stick automount fails
Revision history for this message
Tormod Volden (tormodvolden) wrote :

Thanks for taking the time to report this bug. Can you provide some more details ? What exactly is the error message ? Does the USB stick work on another computer or with another operating system ?

Revision history for this message
Owdy (osku) wrote : dmesg.txt, gvm.log, lshal.txt

Includes dmesg.txt, gvm.log, lshal.txt

Revision history for this message
Owdy (osku) wrote :

It works fine under Windows. It works also with Ubuntu if i manually mount it. I attach that error.

Revision history for this message
Owdy (osku) wrote : Error

This i got when i try open that drive

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Thanks, I saw the attachment. Can you run:
dmesg|tail
in a Terminal window, just after you've plugged the stick, and post the result ?

Revision history for this message
Owdy (osku) wrote :

osku@Koti:~$ dmesg|tail
[4327688.729000] sdb: Write Protect is off
[4327688.729000] sdb: Mode Sense: 0b 00 00 08
[4327688.729000] sdb: assuming drive cache: write through
[4327688.757000] SCSI device sdb: 1001472 512-byte hdwr sectors (513 MB)
[4327688.757000] sdb: Write Protect is off
[4327688.757000] sdb: Mode Sense: 0b 00 00 08
[4327688.757000] sdb: assuming drive cache: write through
[4327688.757000] /dev/scsi/host10/bus0/target0/lun0: p1
[4327688.760000] Attached scsi removable disk sdb at scsi10, channel 0, id 0, lun 0
[4327688.761000] usb-storage: device scan complete

Revision history for this message
Owdy (osku) wrote :

Also got this:

osku@Koti:~$ dmesg|tail
[4327860.767000] atkbd.c: Use 'setkeycodes e02a <keycode>' to make it known.
[4327866.864000] usb 6-6: USB disconnect, address 13
[4327870.780000] usb 6-6: new high speed USB device using ehci_hcd and address 14
[4327870.972000] scsi13 : SCSI emulation for USB Mass Storage devices
[4327870.974000] usb-storage: device found at 14
[4327870.974000] usb-storage: waiting for device to settle before scanning
[4327872.711000] atkbd.c: Unknown key pressed (translated set 2, code 0xaa on isa0060/serio0).
[4327872.711000] atkbd.c: Use 'setkeycodes e02a <keycode>' to make it known.
[4327872.807000] atkbd.c: Unknown key released (translated set 2, code 0xaa on isa0060/serio0).
[4327872.807000] atkbd.c: Use 'setkeycodes e02a <keycode>' to make it known.
osku@Koti:~$ dmesg|tail
[4327875.995000] sdb: Write Protect is off
[4327875.995000] sdb: Mode Sense: 0b 00 00 08
[4327875.995000] sdb: assuming drive cache: write through
[4327875.995000] /dev/scsi/host13/bus0/target0/lun0: p1
[4327875.997000] Attached scsi removable disk sdb at scsi13, channel 0, id 0, lun 0
[4327875.999000] usb-storage: device scan complete
[4327891.826000] atkbd.c: Unknown key pressed (translated set 2, code 0xaa on isa0060/serio0).
[4327891.826000] atkbd.c: Use 'setkeycodes e02a <keycode>' to make it known.
[4327891.990000] atkbd.c: Unknown key released (translated set 2, code 0xaa on isa0060/serio0).
[4327891.990000] atkbd.c: Use 'setkeycodes e02a <keycode>' to make it known.

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Sorry for the lag and crossposting :) Thanks for the extra info. Can you also tell us which Ubuntu version this is, which version of gnome-volume-manager etc ?
Finally, what kind of file system is it ? What is the relevant output of the mount command after you have mounted it manually ?

Revision history for this message
Owdy (osku) wrote :

Its Breezy badger, gnome-volume-manager is latest, 1.4.0-ubuntu6. File system is FAT16.

I dont understand that last guestion. If i put this to /etc/fstab, it mounts:

 /dev/sdb1 /media/usbstick vfat rw,user,noauto,sync,noatime 0 0

But then i have 2 of them, mine works, default one arent.

Revision history for this message
Tormod Volden (tormodvolden) wrote :

About the last question: the command mount (with no arguments) lists all mounted devices. What does it say about /dev/sdb1 ?

I think the interesting part is this in gvm.log:
manager.c/1619: New Device: /org/freedesktop/Hal/devices/storage_model_DataTraveler_2_0
manager.c/1642: not a mountable volume: /org/freedesktop/Hal/devices/storage_model_DataTraveler_2_0

Revision history for this message
Owdy (osku) wrote :

After i manually mounted it (with that etc/fstab thing), command mount gives me this:

/dev/sdb1 on /media/usbstick type vfat (rw,noexec,nosuid,nodev,sync,noatime,user=osku)

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Assigning it to gnome-volume-manager, in hope of getting it some competent love.

Last question: Did you try creating a new user account to see if this has to do with some of your settings ?

Revision history for this message
Owdy (osku) wrote :

I did try now. Same error.

Changed in gnome-volume-manager:
assignee: nobody → pitti
assignee: pitti → nobody
Revision history for this message
Martin Pitt (pitti) wrote :

useless task

Revision history for this message
Owdy (osku) wrote :

Useless? You dont think automount in Ubuntu should work? Usb-stick are very common these days and every os recognize them automaticly. But you think Ubuntu dont have to?

Revision history for this message
Martin Pitt (pitti) wrote :

hal does not recognize the first partition on the stick, it just creates a node for the raw device.

To debug this further, I need some more debug info. Can you please generate a full hald debug output, as described on the second half of http://wiki.ubuntu.com/DebuggingRemovableDevices?

Also, do you have the chance to try out a current Dapper live CD?

Thank you!

Changed in gnome-volume-manager:
assignee: nobody → pitti
status: Unconfirmed → Needs Info
Revision history for this message
Martin Pitt (pitti) wrote :

> Useless? You dont think automount in Ubuntu should work? Usb-stick are very common these days and every os recognize them automaticly. But you think Ubuntu dont have to?

Sorry for the misunderstanding. This bug has two tasks, one for hal in Ubuntu, the other for just 'Ubuntu'. The bug is in hal, so the hal task is relevant, but we don't need the additional 'Ubuntu' task.

Revision history for this message
Owdy (osku) wrote : hal.log

I dont have Dapper live CD, sorry.

Revision history for this message
Owdy (osku) wrote :

>Sorry for the misunderstanding.

No problem. Btw should i create that log without my manual mount? (that etc/fstab thing)

Revision history for this message
Owdy (osku) wrote : Recreated

Recretaed without manually mount

Revision history for this message
Owdy (osku) wrote :

I tested this with Breezy and Dapper live-cd's. Both worked fine. I'm confused :D

Revision history for this message
Martin Pitt (pitti) wrote :

13681: 12:10:48.690: addon-storage.c:283: open failed for /dev/sdb: Permission denied

This looks fairly straightforward - Can you please give me the output of

  ls -l /dev/sd*
  id hal

? Thanks!

Revision history for this message
Owdy (osku) wrote :

osku@Koti:~$ ls -l /dev/sd*
brw-rw---- 1 root disk 8, 0 2006-02-14 19:49 /dev/sda
brw-rw---- 1 root disk 8, 1 2006-02-14 19:49 /dev/sda1
brw-rw---- 1 root disk 8, 2 2006-02-14 19:49 /dev/sda2
brw-rw---- 1 root disk 8, 3 2006-02-14 19:49 /dev/sda3
brw-rw---- 1 root disk 8, 4 2006-02-14 19:49 /dev/sda4
brw-rw---- 1 root disk 8, 5 2006-02-14 19:49 /dev/sda5
brw-rw---- 1 root disk 8, 6 2006-02-14 19:49 /dev/sda6
osku@Koti:~$ id hal
uid=113(hal) gid=113(hal) ryhmät=113(hal)

Revision history for this message
Owdy (osku) wrote :

With usb stick plugged:

osku@Koti:~$ ls -l /dev/sd*
brw-rw---- 1 root disk 8, 0 2006-02-14 19:49 /dev/sda
brw-rw---- 1 root disk 8, 1 2006-02-14 19:49 /dev/sda1
brw-rw---- 1 root disk 8, 2 2006-02-14 19:49 /dev/sda2
brw-rw---- 1 root disk 8, 3 2006-02-14 19:49 /dev/sda3
brw-rw---- 1 root disk 8, 4 2006-02-14 19:49 /dev/sda4
brw-rw---- 1 root disk 8, 5 2006-02-14 19:49 /dev/sda5
brw-rw---- 1 root disk 8, 6 2006-02-14 19:49 /dev/sda6
brw-r----- 1 root plugdev 8, 16 2006-02-14 17:52 /dev/sdb
brw-r----- 1 root plugdev 8, 17 2006-02-14 17:52 /dev/sdb1

Revision history for this message
Dennis Kaarsemaker (dennis) wrote :

Your hal user is messed up:
dennis@mirage ~ $ id hal
uid=109(hal) gid=109(hal) groups=109(hal),24(cdrom),25(floppy),103(plugdev)

Revision history for this message
Martin Pitt (pitti) wrote :

osku@Koti:~$ id hal
uid=113(hal) gid=113(hal) ryhmät=113(hal)

I expected something like this. Did you change this manually at some point?

If not (which is what I assume), do you have any idea which actions caused this? THis is a duplicate of bug #26338 then, but I still don't know how to reproduce it.

Thanks!

Revision history for this message
Owdy (osku) wrote :

>Did you change this manually at some point?

No i didnt. How do i fix that?

Revision history for this message
Dennis Kaarsemaker (dennis) wrote :

sudo adduser hal cdrom
sudo adduser hal floppy
sudo adduser hal plugdev

Revision history for this message
Owdy (osku) wrote :

That didnt help

Revision history for this message
Dennis Kaarsemaker (dennis) wrote :

You may need to reboot

Revision history for this message
Owdy (osku) wrote :

Reboot didnt help.

I installed libpmount 0.0 and its started to work! I got this tip from finnish Ubuntu community http://forum.ubuntu-fi.org/index.php?topic=1476.msg14152#msg14152

Revision history for this message
Martin Pitt (pitti) wrote :

Hm, this is really worrysome. libpmount0.0 has absolutely nothing to do with Ubuntu's automount magic (despite the name similarity with pmount). The three adduser command should have made it work. Can you please purge libpmount0.0 again and do the http://wiki.ubuntu.com/DebuggingRemovableDevices steps again?

Thanks!

Martin

Revision history for this message
Owdy (osku) wrote :

Thats really weird because it started to wor right after i installed that. Well i removed it now, its still working. I attach reports.

Revision history for this message
Owdy (osku) wrote : Reports

Log files

Revision history for this message
Martin Pitt (pitti) wrote :

Thanks; however, the log files don't help me if it's working now. Can you reproduce the bug again without libpmount?

Revision history for this message
Owdy (osku) wrote :

I dont know what broke it before. So i cant, sorry :(

Revision history for this message
Owdy (osku) wrote :

HAA, i can reproduce it. Its broken again. I did it like in that topic https://launchpad.net/distros/ubuntu/+bug/26338

Steps:
-Created new user
-changed my own password
-logged in with new user
-logged in with my own
-deleted new user and changed my password back
-reboot and its broken again: Error: could not execute pmount

I make new logs for you.

Revision history for this message
Owdy (osku) wrote : New logs

New log files

Revision history for this message
Martin Pitt (pitti) wrote :

Thanks a million for that recipe. I will try to reproduce it; it seems that users-admin sometimes messes up the group file.

Revision history for this message
Martin Pitt (pitti) wrote :

BTW, can we please continue the discussion about this bug in https://launchpad.net/distros/ubuntu/+bug/26338 , so that we have a central place? I will close this bug as a duplicate now.

Revision history for this message
Martin Pitt (pitti) wrote :

dup of #26338

Changed in hal:
status: Needs Info → Rejected
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.