udisks2 unable automount USB thumb disk immediately in 10.1

New to Debian (Or Linux in general)? Ask your questions here!

udisks2 unable automount USB thumb disk immediately in 10.1

Postby chenshaoju » 2019-10-02 02:02

Sorry for my English.

I'm a newbie Debian user.

After installed Debian 10.1, I noticed an issue about insert USB thumb disk.

When I insert USB thumb disk to computer, Nothing shows up in "Files".

But in "Disks", I can see a USB thumb disk, But it only has "Free Space".

If waiting 1 min 30 sec after USB thumb disk inserted, The USB thumb disk will show in "Files".

I Googled, This issue may cause by udisks2, But I don't know how to fix this issue.

I collect the log from udisks2 (version 2.8.1-4) ,here is:
Code: Select all
01:02:58.446: Added /org/freedesktop/UDisks2/drives/Kingston_DataTraveler_2_2e0_0DE1B46101F30AC3
  org.freedesktop.UDisks2.Drive:
    CanPowerOff:                true
    Configuration:              {}
    ConnectionBus:              usb
    Ejectable:                  true
    Id:                         Kingston-DataTraveler-2.0-0DE1B46101F30AC3
    Media:                     
    MediaAvailable:             false
    MediaChangeDetected:        true
    MediaCompatibility:         thumb
    MediaRemovable:             false
    Model:                      DataTraveler 2.0
    Optical:                    false
    OpticalBlank:               false
    OpticalNumAudioTracks:      0
    OpticalNumDataTracks:       0
    OpticalNumSessions:         0
    OpticalNumTracks:           0
    Removable:                  true
    Revision:                   6.16
    RotationRate:               -1
    Seat:                       seat0
    Serial:                     0DE1B46101F30AC3
    SiblingId:                  /sys/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.2/1-1.2:1.0
    Size:                       0
    SortKey:                    01hotplug/1569949378444743
    TimeDetected:               1569949378444743
    TimeMediaDetected:          0
    Vendor:                     Kingston
    WWN:                       
01:02:58.454: Added /org/freedesktop/UDisks2/block_devices/sdb
  org.freedesktop.UDisks2.Block:
    Configuration:              []
    CryptoBackingDevice:        '/'
    Device:                     /dev/sdb
    DeviceNumber:               2064
    Drive:                      '/org/freedesktop/UDisks2/drives/Kingston_DataTraveler_2_2e0_0DE1B46101F30AC3'
    HintAuto:                   true
    HintIconName:               
    HintIgnore:                 false
    HintName:                   
    HintPartitionable:          true
    HintSymbolicIconName:       
    HintSystem:                 false
    Id:                         by-id-usb-Kingston_DataTraveler_2.0_0DE1B46101F30AC3-0:0
    IdLabel:                   
    IdType:                     
    IdUUID:                     
    IdUsage:                   
    IdVersion:                 
    MDRaid:                     '/'
    MDRaidMember:               '/'
    PreferredDevice:            /dev/sdb
    ReadOnly:                   false
    Size:                       0
    Symlinks:                   /dev/disk/by-id/usb-Kingston_DataTraveler_2.0_0DE1B46101F30AC3-0:0
                                /dev/disk/by-path/pci-0000:00:1a.0-usb-0:1.2:1.0-scsi-0:0:0:0
    UserspaceMountOptions:     
01:03:01.987: /org/freedesktop/UDisks2/block_devices/sdb: Added interface org.freedesktop.UDisks2.PartitionTable
  Partitions:           []
  Type:                 
01:03:01.988: /org/freedesktop/UDisks2/block_devices/sdb: org.freedesktop.UDisks2.Block: Properties Changed
  Size:                 1026555392
01:03:02.119: /org/freedesktop/UDisks2/drives/Kingston_DataTraveler_2_2e0_0DE1B46101F30AC3: org.freedesktop.UDisks2.Drive: Properties Changed
  TimeMediaDetected:            1569949382116463
  Media:                        thumb
  MediaAvailable:               true
  Size:                         1026555392
01:03:02.119: /org/freedesktop/UDisks2/block_devices/sdb: org.freedesktop.UDisks2.PartitionTable: Properties Changed
  Type:                 dos
01:04:32.893: Added /org/freedesktop/UDisks2/block_devices/sdb1
  org.freedesktop.UDisks2.Block:
    Configuration:              []
    CryptoBackingDevice:        '/'
    Device:                     /dev/sdb1
    DeviceNumber:               2065
    Drive:                      '/org/freedesktop/UDisks2/drives/Kingston_DataTraveler_2_2e0_0DE1B46101F30AC3'
    HintAuto:                   true
    HintIconName:               
    HintIgnore:                 false
    HintName:                   
    HintPartitionable:          true
    HintSymbolicIconName:       
    HintSystem:                 false
    Id:                         by-id-usb-Kingston_DataTraveler_2.0_0DE1B46101F30AC3-0:0-part1
    IdLabel:                    USB DISK
    IdType:                     vfat
    IdUUID:                     C14D-581B
    IdUsage:                    filesystem
    IdVersion:                  FAT32
    MDRaid:                     '/'
    MDRaidMember:               '/'
    PreferredDevice:            /dev/sdb1
    ReadOnly:                   false
    Size:                       1026523136
    Symlinks:                   /dev/disk/by-id/usb-Kingston_DataTraveler_2.0_0DE1B46101F30AC3-0:0-part1
                                /dev/disk/by-label/USB\x20DISK
                                /dev/disk/by-path/pci-0000:00:1a.0-usb-0:1.2:1.0-scsi-0:0:0:0-part1
                                /dev/disk/by-uuid/C14D-581B
    UserspaceMountOptions:     
  org.freedesktop.UDisks2.Filesystem:
    MountPoints:       
    Size:               0
  org.freedesktop.UDisks2.Partition:
    Flags:              128
    IsContained:        false
    IsContainer:        false
    Name:               
    Number:             1
    Offset:             16384
    Size:               1026523136
    Table:              '/org/freedesktop/UDisks2/block_devices/sdb'
    Type:               0x0b
    UUID:               
01:04:32.893: /org/freedesktop/UDisks2/block_devices/sdb: org.freedesktop.UDisks2.PartitionTable: Properties Changed
  Partitions:           ['/org/freedesktop/UDisks2/block_devices/sdb1']
01:04:43.017: Added /org/freedesktop/UDisks2/jobs/5
  org.freedesktop.UDisks2.Job:
    Bytes:              0
    Cancelable:         true
    ExpectedEndTime:    0
    Objects:            ['/org/freedesktop/UDisks2/block_devices/sdb1']
    Operation:          filesystem-mount
    Progress:           0.0
    ProgressValid:      false
    Rate:               0
    StartTime:          1569949483014006
    StartedByUID:       0
01:04:43.039: /org/freedesktop/UDisks2/jobs/5: org.freedesktop.UDisks2.Job::Completed (true, '')
01:04:43.040: Removed /org/freedesktop/UDisks2/jobs/5
01:04:43.051: /org/freedesktop/UDisks2/block_devices/sdb1: org.freedesktop.UDisks2.Filesystem: Properties Changed
  MountPoints:          /media/chenshaoju/USB DISK
01:04:43.051: /org/freedesktop/UDisks2/block_devices/sdb1: org.freedesktop.UDisks2.Block: Properties Changed
  UserspaceMountOptions:        uhelper=udisks2
01:05:06.130: /org/freedesktop/UDisks2/drives/Maxsun__120GB_A6_AA000000000000001517: org.freedesktop.UDisks2.Drive.Ata: Properties Changed
  SmartPowerOnSeconds:          97200
  SmartUpdated:                 1569949506


Thank you.
chenshaoju
 
Posts: 1
Joined: 2019-10-02 01:49

Re: udisks2 unable automount USB thumb disk immediately in 1

Postby arzgi » 2019-11-27 21:12

From udisks man page:
Code: Select all
AUDIENCE
       The intended audience of udisks include operating system developers working on
       the higher-level parts of the operating system, for example the desktop shell
       (such as GNOME[5]) and disk management applications (e.g. GNOME's Disks[6]
       application).


You should not need to tinker with it.

You did not say, do you use any DE, like Gnome, KDE, Xfce,... but can you open some terminal program, give command
Code: Select all
groups


and post the output here. An example:
Code: Select all
~$ groups
arto cdrom floppy sudo audio dip video plugdev netdev
arzgi
 
Posts: 475
Joined: 2008-02-21 17:03
Location: Finland

Re: udisks2 unable automount USB thumb disk immediately in 1

Postby None1975 » 2019-11-29 15:57

Hello. You can try udiskie. It is udisks2 automounter with optional notifications, tray icon and support for password protected LUKS devices.
OS: Debian 10.1 Buster / WM: fvwm
Debian Wiki | DontBreakDebian, My config files in github
User avatar
None1975
 
Posts: 956
Joined: 2015-11-29 18:23
Location: Lithuania, Vilnius

Re: udisks2 unable automount USB thumb disk immediately in 1

Postby L_V » 2019-11-29 16:24

chenshaoju wrote:But in "Disks", I can see a USB thumb disk, But it only has "Free Space"..

You cannot mount a USB key with no partition, or no partition table.
If no partition is visible, first check integrity of your USB key with gparted for example.
L_V
 
Posts: 1171
Joined: 2007-03-19 09:04

Re: udisks2 unable automount USB thumb disk immediately in 1

Postby Head_on_a_Stick » 2019-12-01 09:39

L_V wrote:You cannot mount a USB key with no partition, or no partition table.

Of course you can:
Code: Select all
empty@E485:~ $ sudo mount /dev/sdb /mnt
empty@E485:~ $ grep mnt /proc/self/mounts
/dev/sdb /mnt f2fs rw,lazytime,relatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,alloc_mode=default,fsync_mode=posix 0 0
empty@E485:~ $

@OP: please plug in the stick and post the output of
Code: Select all
parted --list

Thanks!
Don't break DebianHow to report bugs

SharpBang GNU/Linux® — a pre-configured Openbox/Tint2 desktop running on Debian stable
User avatar
Head_on_a_Stick
 
Posts: 10695
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: udisks2 unable automount USB thumb disk immediately in 1

Postby L_V » 2019-12-01 10:32

Head_on_a_Stick wrote:Of course you can

On which directory udisks2 will mount a drive with no formatted partition ?
L_V
 
Posts: 1171
Joined: 2007-03-19 09:04

Re: udisks2 unable automount USB thumb disk immediately in 1

Postby Head_on_a_Stick » 2019-12-01 10:42

L_V wrote:On which directory udisks2 will mount a drive with no formatted partition ?

Code: Select all
empty@E485:~ $ grep sdb /proc/self/mounts
/dev/sdb /media/empty/8d6cda6b-23ac-46d5-a228-5e07a485a3d1 f2fs rw,lazytime,nosuid,nodev,relatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,alloc_mode=default,fsync_mode=posix 0 0
empty@E485:~ $

EDIT: the stick is formatted but lacks a partition table.
Don't break DebianHow to report bugs

SharpBang GNU/Linux® — a pre-configured Openbox/Tint2 desktop running on Debian stable
User avatar
Head_on_a_Stick
 
Posts: 10695
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: udisks2 unable automount USB thumb disk immediately in 1

Postby L_V » 2019-12-01 11:55

L_V wrote:You cannot mount a USB key with no partition, or no partition table.
If no partition is visible, first check integrity of your USB key with gparted for example.
Head_on_a_Stick wrote:Of course you can
Head_on_a_Stick wrote:the stick is formatted but lacks a partition table.

Not sure to understand your primary disagreement concerning udisks2 mounting rules.
Let's hope it will be clear for chenshaoju.
L_V
 
Posts: 1171
Joined: 2007-03-19 09:04


Return to Beginners Questions

Who is online

Users browsing this forum: No registered users and 6 guests

fashionable