Bug 331054

Summary: System doesn't mount USB pendrive nor display it in fdisk
Product: [openSUSE] openSUSE 10.3 Reporter: Rafał Miłecki <zajec5>
Component: KernelAssignee: E-mail List <kernel-maintainers>
Status: RESOLVED NORESPONSE QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: edwardsg, jeffm, mlj, s.illes79, wharms
Version: Final   
Target Milestone: ---   
Hardware: i686   
OS: openSUSE 10.3   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: dmesg log (tailed) after plugging in pendrive
mount command output after plugging in pendrive
fdisk -l command output after plugging in pendrive
hwinfo --disk command output after plugging in pendrive
hwinfo before plugging in USB
hwinfo direct after plugging in USB
hwinfo after plugging in and modprobe usb_storage

Description Rafał Miłecki 2007-10-05 12:07:45 UTC
When I plugin USB pendrive to my computer some info appears in dmesg but disk is not being mounted. I can't see it in "mount" command or "fdisk -l". However hwinfo --disk see my pendrive.
Comment 1 Rafał Miłecki 2007-10-05 12:09:49 UTC
Created attachment 176495 [details]
dmesg log (tailed) after plugging in pendrive
Comment 2 Rafał Miłecki 2007-10-05 12:10:39 UTC
Created attachment 176496 [details]
mount command output after plugging in pendrive
Comment 3 Rafał Miłecki 2007-10-05 12:11:15 UTC
Created attachment 176497 [details]
fdisk -l command output after plugging in pendrive
Comment 4 Rafał Miłecki 2007-10-05 12:11:58 UTC
Created attachment 176499 [details]
hwinfo --disk command output after plugging in pendrive
Comment 5 Michael Jenkinson 2007-10-07 20:09:20 UTC
This is I think similar to my USB detection problem with 10.3 final 386 version

solved by loading this version of hal

http://download.opensuse.org/repositories/home:/dkukawka:/hal-beta/openSUSE_Factory/

and rebooting.

Hal is broken in both 64 bit and 32 bit versions in final as far as net postings suggest. see http://www.suseforums.net/index.php?showtopic=39451

A major bug that may be a recursion. I have upped its severity by my rating as it is the most obvious mistake in the distro that would be a turn off for any newbie and easy to sort with a beta hal
Comment 6 Matej Horvath 2007-10-08 13:09:50 UTC
Rafał Miłecki: could you please try to install hal from the openSuSE Factory? 
Comment 7 Rafał Miłecki 2007-10-08 14:58:58 UTC
Sure, just needed a one day ;-)

I downgraded default hal-0.5.9_git20070831-13 to hal-0.5.9_git20070807-7.6 but it didn't help. I rebooted computer, plugged in pendrive and effect is that same. Pendrive wasn't mounted and fdisk -l still doesn't show this pendrive.
Comment 8 a b 2007-10-10 15:40:56 UTC
I just did the same, the downgrade did not work.
starting hald as not daemon (see man hald)
shows (a lot of traffic): (the version from the DVD has only 
"CRITICAL **: polkit_session_get_ck_objref: assertion `session != NULL' failed")

<cut a lot of noise>

17:31:53.309 [I] ci-tracker.c:435: =========================

** (process:6617): CRITICAL **: _pk_validate_identifier: assertion `identifier != NULL' failed

** (process:6617): CRITICAL **: polkit_caller_set_selinux_context: assertion `_pk_validate_identifier (selinux_context)' failed

** (process:6617): CRITICAL **: polkit_session_get_ck_objref: assertion `session != NULL' failed
17:31:53.311 [I] hald_dbus.c:5166: ************************
17:31:53.311 [I] hald_dbus.c:5167: Client to local_server was disconnected for 80fd2a0
17:31:53.311 [I] hald_dbus.c:5168: ************************
17:31:53.311 [I] hald_dbus.c:5209: ***************************
17:31:53.311 [I] hald_dbus.c:5210: ********* unregistered 80fd2a0
17:31:53.311 [I] hald_dbus.c:5211: ***************************
17:31:53.312 [I] device.c:1811: Removing locks from ':1.85'
/usr/lib/hal/hal-storage-mount exited
17:31:53.313 [I] hald_dbus.c:3944: No more methods in queue
17:31:53.313 [I] hald_dbus.c:4007: failed with 'org.freedesktop.Hal.Device.PermissionDeniedByPolicy' 'hal-storage-mount-removable no <-- (action, result)'
17:31:53.374 [I] ci-tracker.c:212: Removing CICallerInfo object for :1.84

<cut less noise>


Comment 9 Danny Al-Gaaf 2007-10-12 11:07:41 UTC
1) don't do stupid thinks like downgrade the package to an old (inofficial) version of a package if you wasn't ask for.

2) since the media isn't listed in fdisk and also not in dmesg (usb-storage info missing) I would say it's a hardware or kernel problem. Reassign it to the kernel ppl.
Comment 10 a b 2007-10-17 12:46:05 UTC
i did some more investigation on OpenSuSE 10.3 default installation.

hier my dmesg: 
scsi 3:0:0:0: Direct-Access              USB Flash Memory 1.00 PQ: 0 ANSI: 2
sd 3:0:0:0: [sdb] 2002944 512-byte hardware sectors (1026 MB)
sd 3:0:0:0: [sdb] Write Protect is off
sd 3:0:0:0: [sdb] Mode Sense: 0b 00 00 08
sd 3:0:0:0: [sdb] Assuming drive cache: write through
sd 3:0:0:0: [sdb] 2002944 512-byte hardware sectors (1026 MB)
sd 3:0:0:0: [sdb] Write Protect is off
sd 3:0:0:0: [sdb] Mode Sense: 0b 00 00 08
sd 3:0:0:0: [sdb] Assuming drive cache: write through
 sdb: sdb1 sdb2
sd 3:0:0:0: [sdb] Attached SCSI removable disk
sd 3:0:0:0: Attached scsi generic sg2 type 0
usb-storage: device scan complete

everything is properly detected (manual mounting works fine)
 
/* hald in debug mode after reboot with usb attached */
/* sdb ist detected but not mounted */

[4289]: 14:19:34.432 [D] addon-storage.c:672: **************************************************
[4284]: 14:19:49.643 [I] addon-storage.c:346: Checking whether device /dev/sdb is locked on HAL
[4284]: 14:19:49.644 [I] addon-storage.c:354: ... device /dev/sdb is not locked on HAL
[4289]: 14:19:50.435 [I] addon-storage.c:346: Checking whether device /dev/sr0 is locked on HAL
[4289]: 14:19:50.436 [I] addon-storage.c:354: ... device /dev/sr0 is not locked on HAL
14:20:02.314 [D] device_pm.c:101: Current voltage is unknown, smaller than 50% or greater than design


/* usb in/out */

14:21:35.090 [I] blockdev.c:379: entering; exit_type=0, return_code=0
14:21:35.099 [I] blockdev.c:133: Add callouts completed udi=/org/freedesktop/Hal/devices/volume_uuid_4446_70D7
14:21:35.099 [I] hald.c:108: Added device to GDL; udi=/org/freedesktop/Hal/devices/volume_uuid_4446_70D7
14:21:35.099 [E] util.c:190: Cannot open '/sys/block/sdb/sdb1/range'
14:21:35.099 [I] osspec.c:863: hal_util_find_known_parent: '/sys/block/sdb/sdb1'->'/sys/block/sdb'
14:21:35.099 [I] blockdev.c:856: block_add: sysfs_path=/sys/block/sdb/sdb1 dev=/dev/sdb1 is_part=1, parent=0x080ca460
Run started hald-probe-volume (10000) (0) 
!  full path is '/usr/lib/hal/hald-probe-volume', program_dir is '/usr/lib/hal'
14:21:35.102 [I] hald_dbus.c:5243: ***************************
14:21:35.102 [I] hald_dbus.c:5244: ********* got a connection 80ffec0
14:21:35.102 [I] hald_dbus.c:5245: ***************************
[4336]: 14:21:35.102 [D] probe-volume.c:372: Doing probe-volume for /dev/sdb1

<lots off alloc debug stuff removed>

[4336]: 14:21:35.121 [I] probe-volume.c:618: volume_id_probe_all returned 0
[4336]: 14:21:35.121 [D] probe-volume.c:107: volume.fsusage = 'filesystem'
[4336]: 14:21:35.121 [D] probe-volume.c:113: volume.fstype = 'ext2'
[4336]: 14:21:35.121 [D] probe-volume.c:118: volume.fsversion = '1.0'
[4336]: 14:21:35.121 [D] probe-volume.c:123: volume.uuid = '31e5dc22-2973-45d3-9177-12b2750719fe'
[4336]: 14:21:35.121 [I] probe-volume.c:690: Loading part table
[4336]: 14:21:35.168 [I] partutil.c:860: MSDOS partition table detected
[4336]: 14:21:35.168 [I] probe-volume.c:696: Looking at part table
[4336]: 14:21:35.168 [I] probe-volume.c:769: Done looking at part table
14:21:35.168 [I] hald_dbus.c:1261: volume.block_size -> 512
14:21:35.168 [I] hald_dbus.c:1269: volume.size -> 756693504
14:21:35.168 [I] hald_dbus.c:1253: volume.fsusage -> filesystem
14:21:35.168 [I] hald_dbus.c:1253: volume.fstype -> ext2
14:21:35.168 [I] hald_dbus.c:1253: volume.fsversion -> 1.0
14:21:35.168 [I] hald_dbus.c:1253: volume.uuid -> 31e5dc22-2973-45d3-9177-12b2750719fe
14:21:35.168 [I] hald_dbus.c:1253: info.product -> Volume (ext2)
14:21:35.168 [I] hald_dbus.c:1253: volume.partition.scheme -> mbr
14:21:35.169 [I] hald_dbus.c:1253: volume.partition.type -> 0x83
14:21:35.169 [I] hald_dbus.c:1253: volume.partition.label -> 
14:21:35.169 [I] hald_dbus.c:1253: volume.partition.uuid -> 
14:21:35.170 [I] hald_dbus.c:5186: ************************
14:21:35.170 [I] hald_dbus.c:5187: Client to local_server was disconnected for 80ffec0
14:21:35.170 [I] hald_dbus.c:5188: ************************
14:21:35.170 [I] hald_dbus.c:5229: ***************************
14:21:35.170 [I] hald_dbus.c:5230: ********* unregistered 80ffec0
14:21:35.170 [I] hald_dbus.c:5231: ***************************
/usr/lib/hal/hald-probe-volume exited
14:21:35.171 [I] blockdev.c:379: entering; exit_type=0, return_code=0
14:21:35.185 [I] blockdev.c:133: Add callouts completed udi=/org/freedesktop/Hal/devices/volume_uuid_31e5dc22_2973_45d3_9177_12b27507
19fe
14:21:35.185 [I] hald.c:108: Added device to GDL; udi=/org/freedesktop/Hal/devices/volume_uuid_31e5dc22_2973_45d3_9177_12b2750719fe

the strange "polkit_session_get_ck_objref: assertion
`session != NULL' failed" foes not happen anymore


Comment 11 a b 2007-10-17 12:56:32 UTC
I guess i have found the problem: using halmount as normal user cause problems
as root it seems to work ok. i have no clue why automount still does not work.


/* as normal user */
 halmount /dev/sdb1
/dev/sdb1: org.freedesktop.Hal.Device.PermissionDeniedByPolicy: hal-storage-mount-removable no <-- (action, result)


/* hald debug output: */
trying dir /media/disk
allowed_options[0] = 'ro'
allowed_options[1] = 'sync'
allowed_options[2] = 'dirsync'
allowed_options[3] = 'noatime'
allowed_options[4] = 'nodiratime'
allowed_options[5] = 'noexec'
allowed_options[6] = 'quiet'
allowed_options[7] = 'remount'
allowed_options[8] = 'exec'
allowed_options[9] = 'acl'
allowed_options[10] = 'user_xattr'
using action hal-storage-mount-removable for uid 1000, system_bus_connection :1.68

** (process:5283): CRITICAL **: polkit_session_get_ck_objref: assertion `session != NULL' failed
14:58:20.195 [I] hald_dbus.c:5186: ************************
14:58:20.195 [I] hald_dbus.c:5187: Client to local_server was disconnected for 8129980
14:58:20.195 [I] hald_dbus.c:5188: ************************
14:58:20.195 [I] hald_dbus.c:5229: ***************************
14:58:20.195 [I] hald_dbus.c:5230: ********* unregistered 8129980
14:58:20.195 [I] hald_dbus.c:5231: ***************************
14:58:20.195 [I] device.c:1845: Removing locks from ':1.69'
/usr/lib/hal/hal-storage-mount exited


/* doing the same a root */
 halmount /dev/sdb1
/dev/sdb1 mounted on /media/disk

/* hald output */

mount_point    = ''
mount_fstype   = ''
mount_options  = '      '
trying dir /media/disk
allowed_options[0] = 'ro'
allowed_options[1] = 'sync'
allowed_options[2] = 'dirsync'
allowed_options[3] = 'noatime'
allowed_options[4] = 'nodiratime'
allowed_options[5] = 'noexec'
allowed_options[6] = 'quiet'
allowed_options[7] = 'remount'
allowed_options[8] = 'exec'
allowed_options[9] = 'acl'
allowed_options[10] = 'user_xattr'
using action hal-storage-mount-removable for uid 0, system_bus_connection :1.70
passed privilege
5425: XYA creating /media/.hal-mtab~
5425: XYA closing /media/.hal-mtab~
14:59:55.720 [I] osspec.c:256: /proc/mounts tells, that the mount has tree changed
5425: XYA done renaming /media/.hal-mtab~ to /media/.hal-mtab
5425: XYA released lock on /media/.hal-mtab-lock
/usr/lib/hal/hal-storage-mount exited
14:59:55.721 [I] hald_dbus.c:3962: No more methods in queue
14:59:55.721 [I] hald_dbus.c:5186: ************************
14:59:55.721 [I] hald_dbus.c:5187: Client to local_server was disconnected for 80d87c0
14:59:55.721 [I] hald_dbus.c:5188: ************************
14:59:55.721 [I] hald_dbus.c:5229: ***************************
14:59:55.721 [I] hald_dbus.c:5230: ********* unregistered 80d87c0
14:59:55.721 [I] hald_dbus.c:5231: ***************************
14:59:55.722 [I] device.c:1845: Removing locks from ':1.71'

Comment 12 Szabolcs Illes 2007-10-18 20:21:07 UTC
I have the very same problem, sometimes when I plug an usb mass storage device I get the following message in a popup window

"hal-storage-mount-removeable no <-- (action,result)"

restarting hald does not help, restarting the machine does help !!!
I can mount the drive as root with mount

and this one is from hald --daemon=no

** (process:7619): CRITICAL **: polkit_session_get_ck_objref: assertion `session != NULL' failed
/usr/lib/hal/hal-storage-mount exited
Comment 13 Jeff Mahoney 2007-10-23 18:38:34 UTC
Can you provide the full output of 'hwinfo' after the pen drive has been inserted?
Comment 14 Rafał Miłecki 2007-10-23 21:26:22 UTC
@Jeff Mahoney: please, check attachment id=176499 which was added as Comment #4
Comment 15 Rafał Miłecki 2007-10-23 21:30:47 UTC
Oh, sorry, I didn't read "full" word in your comment. I'll check tomorrow if I still have accesss to this notebook.
Comment 16 Rafał Miłecki 2007-10-26 10:27:32 UTC
Created attachment 180754 [details]
hwinfo before plugging in USB

Output of hwinfo --all after booting system, before plugging in USB pendrive.
Comment 17 Rafał Miłecki 2007-10-26 10:27:49 UTC
Created attachment 180755 [details]
hwinfo direct after plugging in USB

Output of hwinfo --all after plugging in USB pendrive.
Comment 18 Rafał Miłecki 2007-10-26 10:31:41 UTC
Created attachment 180756 [details]
hwinfo after plugging in and modprobe usb_storage

Output of hwinfo --all after I plugged in USB pendrive AND typed "modprobe usb_storage" - according to previous info from hwinfo:
Driver Status: usb_storage is not active
Driver Activation Cmd: "modprobe usb_storage"
Comment 19 Jeff Mahoney 2007-10-31 20:01:29 UTC
Sorry, I wasn't clear. I just need 'hwinfo' Unfortunately, --all actually provides LESS of the information I was looking for. Straight 'hwinfo' provides a more complete picture including the relevant logs.
Comment 20 Greg Kroah-Hartman 2008-02-04 18:40:53 UTC
Closing due to inactivity.