LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   USB drives aren't automounted: Debian Testing (https://www.linuxquestions.org/questions/linux-newbie-8/usb-drives-arent-automounted-debian-testing-884590/)

mike11 06-04-2011 10:54 PM

USB drives aren't automounted: Debian Testing
 
Hi All,

I'm using Debian Testing & it does not automount any external usb devices.

Here's what I've checked:
gconf-edit->app->nautilus->preferences->media_automount: checked
gconf-editor->desktop->gnome->volume_manager->automount_drives & automount_media:checked
no entries for the external usb drives in fstab (following http://forums.debian.net/viewtopic.php?p=342025)
at commandline, groups gives:
Code:

mike dialout cdrom floppy audio video plugdev scanner netdev powerdev
and lsmod|grep usb:
Code:

usb_storage            48564  0
usbhid                31568  0
hid                    34528  1 usbhid
scsi_mod              131800  5 sg,sr_mod,usb_storage,sd_mod,libata
usbcore              126052  5 usb_storage,usbhid,uhci_hcd,ehci_hcd

usb drives aren't mounted even on boot. Also, a card-reader doesn't get automounted, so it's not just a usb drive issue.

Can someone please advice what's going on?

TIA,
Mike.

andrewthomas 06-05-2011 12:00 AM

This could be a polkit/udisks problem

To see if it is: create a /etc/polkit-1/localauthority/50-local.d/my-polkit-udisks.pkla file containing
Code:

[udisks full access]
Identity=unix-group:plugdev[/B]
Action=org.freedesktop.udisks.*
ResultAny=no
ResultInactive=no
ResultActive=yes

You could also use Identity=unix-user:USERNAME
to restrict the privileges to your user

I don't know, but it may be that Debian could be moving away from HAL to udev/udisks/polkit/consolekit

mike11 06-05-2011 08:12 PM

Thanks for replying.

On my machine the closet directory I have is:
Code:

/etc/polkit-1/localauthority.conf.d
which contains a single file:
Code:

50-localauthority.conf
Please advice, thanks.

mike11 06-05-2011 08:17 PM

Also, here's the relevant part of /var/log/syslog when I connect a usb HDD:
Code:

Jun  6 10:13:30 mike1 kernel: [ 1123.837162] usb 2-1: New USB device found, idVendor=04bb, idProduct=0125
Jun  6 10:13:30 mike1 kernel: [ 1123.837165] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Jun  6 10:13:30 mike1 kernel: [ 1123.837167] usb 2-1: Product: HDPN-U         
Jun  6 10:13:30 mike1 kernel: [ 1123.837169] usb 2-1: Manufacturer: I-O DATA
Jun  6 10:13:30 mike1 kernel: [ 1123.837171] usb 2-1: SerialNumber: 0000000000E51FDF
Jun  6 10:13:30 mike1 kernel: [ 1123.837243] usb 2-1: configuration #1 chosen from 1 choice
Jun  6 10:13:30 mike1 kernel: [ 1123.837394] scsi5 : SCSI emulation for USB Mass Storage devices
Jun  6 10:13:30 mike1 kernel: [ 1123.837664] usb-storage: device found at 5
Jun  6 10:13:30 mike1 kernel: [ 1123.837666] usb-storage: waiting for device to settle before scanning
Jun  6 10:13:35 mike1 kernel: [ 1128.836088] usb-storage: device scan complete
Jun  6 10:13:35 mike1 kernel: [ 1128.843447] scsi 5:0:0:0: Direct-Access    I-O DATA HDPN-U          9.60 PQ: 0 ANSI: 0
Jun  6 10:13:35 mike1 kernel: [ 1128.843814] sd 5:0:0:0: Attached scsi generic sg2 type 0
Jun  6 10:13:35 mike1 kernel: [ 1128.844439] sd 5:0:0:0: [sdb] 976773168 512-byte hardware sectors: (500 GB/465 GiB)
Jun  6 10:13:35 mike1 kernel: [ 1128.845309] sd 5:0:0:0: [sdb] Write Protect is off
Jun  6 10:13:35 mike1 kernel: [ 1128.845313] sd 5:0:0:0: [sdb] Mode Sense: 37 00 00 08
Jun  6 10:13:35 mike1 kernel: [ 1128.845315] sd 5:0:0:0: [sdb] Assuming drive cache: write through
Jun  6 10:13:35 mike1 kernel: [ 1128.849028] sd 5:0:0:0: [sdb] Assuming drive cache: write through
Jun  6 10:13:35 mike1 kernel: [ 1128.849032]  sdb: sdb1 sdb2
Jun  6 10:13:35 mike1 kernel: [ 1128.872316] sd 5:0:0:0: [sdb] Attached SCSI disk

TIA.

andrewthomas 06-05-2011 08:34 PM

Then make the directory

Code:

mkdir -p /etc/polkit-1/localauthority/50-local.d/
and create the above .pkla file

then log out and back in and try again.

mike11 06-05-2011 10:09 PM

Done that, still no luck.

andrewthomas 06-05-2011 10:28 PM

Is polkit-gnome-authentication-agent running?

mike11 06-05-2011 10:37 PM

as su, ps x|grep pol gives:
Code:

2074 ?        S      0:00 hald-addon-storage: polling /dev/sr0 (every 2 sec)
 2389 ?        S      0:00 udisks-daemon: polling /dev/sr0
 2411 ?        S      0:00 /usr/lib/policykit-1/polkitd

so by the last line, it looks like it is.
I also have it enabled on system->preferences->startup applications.

This is weired. I have another PC where debian testing automount fine.
Maybe something I've installed or tweaked killed automounting.

andrewthomas 06-05-2011 10:57 PM

Code:

$ ps ax | grep pol
  899 ?        S      0:01 udisks-daemon: polling /dev/sr0 /dev/sdb
 1527 ?        Sl    0:00 /usr/lib/policykit-1-gnome/polkit-gnome-authentication-agent-1
 1550 ?        S      0:08 /usr/lib/policykit-1/polkitd


mike11 06-05-2011 11:26 PM

is it possible you've left out some text?

andrewthomas 06-05-2011 11:29 PM

No. I have no hal.

What I was stating was that you need more than polkitd running, but also polkit-gnome-authentication-agent-1

mike11 06-05-2011 11:38 PM

Ok, thanks.

Well, in system->preferences->startup applications->policykit auth. agent is checked, so it should be running.
is there somewhere it might have been disabled?

roygbiiv 06-06-2011 02:18 PM

Quote:

Originally Posted by mike11 (Post 4376606)
Hi All,

I'm using Debian Testing & it does not automount any external usb devices.

Here's what I've checked:
gconf-edit->app->nautilus->preferences->media_automount: checked
gconf-editor->desktop->gnome->volume_manager->automount_drives & automount_media:checked
no entries for the external usb drives in fstab (following http://forums.debian.net/viewtopic.php?p=342025)
at commandline, groups gives:
Code:

mike dialout cdrom floppy audio video plugdev scanner netdev powerdev
and lsmod|grep usb:
Code:

usb_storage            48564  0
usbhid                31568  0
hid                    34528  1 usbhid
scsi_mod              131800  5 sg,sr_mod,usb_storage,sd_mod,libata
usbcore              126052  5 usb_storage,usbhid,uhci_hcd,ehci_hcd

usb drives aren't mounted even on boot. Also, a card-reader doesn't get automounted, so it's not just a usb drive issue.

Can someone please advice what's going on?

TIA,
Mike.

have you tried adding yourself to the disk group?
Code:

sudo usermod -a -G disk your_username

mike11 06-07-2011 01:02 AM

I don't think the "disk" group is related. There is the "plugdev" group which is, but I already belong to it.

My guess is that something in the gnome automounting mechanism has been disabled on my pc. There seem to be many applications with overlapping actions, at least with respect to automounting: hal, udev, gnome-volume-manager, nautilus, policykit. This makes it more complicated to figure out what's wrong.

Anyway, it's still not working, so would appreciate advice from members.

TIA.


All times are GMT -5. The time now is 02:13 PM.