Xfce How to disable bsdisks automounter?

bsduck

Well-Known Member

Reaction score: 279
Messages: 303

Hello,

Xfce in FreeBSD has been recently including by default a new automounting system, using sysutils/bsdisks.

I experimented a bit with various external drives, and found it totally unreliable as of now.

With the disk formatted
... as UFS, it shows two entries in Thunar (one for /dev/da0 and one for /dev/da0p1) for a single partition disk.
... as ext2, it cannot mount it.
... as exFAT, I end up with gvfs-udisks2-volume-monitor hanging at high CPU usage, when unmounting the disk from Thunar.
... as FAT32, it fails to mount it and crashes, if the disk has UTF-8 filenames (for which there is the -L xx_XX.UTF-8 option when using mount_msdosfs).

I don't understand how such a buggy piece of software can be installed and enabled by default. I have nothing against automounting, but no automounting is for sure better than a mechanism that fails most of the time, being more of an annoyance than something useful.

How can I disable this? I cannot remove bsdisks without breaking dependencies.
 

Jaekelsson

New Member

Reaction score: 6
Messages: 14

I had this problem with XFCE.

I had to disable bsdisks :
The only solution i found is to rename or delete the file :
/usr/local/share/dbus-1/system-services/org.freedesktop.UDisks2.service
bsdisks won't start again.

I'm searching for a better solution.
 

Jaskie

Member

Reaction score: 3
Messages: 23

Any solution now? umount exFat flash drive is eating my CPU now.
 

grahamperrin

Son of Beastie

Reaction score: 1,022
Messages: 3,440

<https://www.freshports.org/sysutils/bsdisks#requiredforRun>

… remove bsdisks without breaking dependencies.

I'm curious, what breakage occurs as a result of forced deletion of the one package?

Code:
root@mowa219-gjp4-8570p-freebsd:~ # pkg delete -f bsdisks
Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 1 packages (of 0 packages in the universe):

Installed packages to be REMOVED:
        bsdisks: 0.26

Number of packages to be removed: 1

Proceed with deinstalling packages? [y/N]:
 

Vull

Aspiring Daemon

Reaction score: 565
Messages: 859

Maybe try installing sysutils/automount rather than disabling automounter altogether?

Can't speak for xfce, but I'm using bsdisks with KDE and with Mate and it works fine, however, in each install I also have Vermaden's sysutils/automount installed. I've been using it for about 3-4 years with no problems.
 
OP
bsduck

bsduck

Well-Known Member

Reaction score: 279
Messages: 303

I'm curious, what breakage occurs as a result of forced deletion of the one package?
That probably wouldn't cause any kind of trouble, but it will be reinstalled automatically whenever packages listing it as a dependency get upgraded.

Any solution now? umount exFat flash drive is eating my CPU now.
As long as this problem doesn't get fixed, don't unmount volumes from the file manager, but use umount from command line instead.

It seems there is no bug report yet, I will open one.
 

dj015

New Member

Reaction score: 14
Messages: 12

I experimented a bit with various external drives, and found it totally unreliable as of now.

With the disk formatted
... as UFS, it shows two entries in Thunar (one for /dev/da0 and one for /dev/da0p1) for a single partition disk.
... as ext2, it cannot mount it.
... as exFAT, I end up with gvfs-udisks2-volume-monitor hanging at high CPU usage, when unmounting the disk from Thunar.
... as FAT32, it fails to mount it and crashes, if the disk has UTF-8 filenames (for which there is the -L xx_XX.UTF-8 option when using mount_msdosfs).

What version of bsdisks is this?

Version 0.24 crashed and hung a lot, and I helped the developer (Gleb Popov) with extensive testing and we found and fixed many issues. Version 0.26 should be stable and reliable, even for edge cases like drives which fail during GEOM probing due to flaky electrical contacts on the USB port.

I don't understand how such a buggy piece of software can be installed and enabled by default. I have nothing against automounting, but no automounting is for sure better than a mechanism that fails most of the time, being more of an annoyance than something useful.

Because only something UDisks-compatible will fully work with all the features on modern desktops. For better or worse, UDisks has become the standard API on all major desktops (GNOME, KDE, XFCE, LXDE). It's not just mounting partitions in modern file managers, it's optical disc tools that want the DBus events for disc inserted/ejected notifications, it's disk management tools, there is disk decryption UI workflows that use those events, there's the "These apps are stopping your drive from unmounting" dialog, there's the "Drive is now safe to remove" notification, Wine wants UDisks and its winecfg tool does less without it, and more. You lose a whole world of desktop functionality by not having UDisks compatibility - and aren't even aware of how much better your desktop experience could be. (Hal had some of those features before, but was buggy and insecure, and hal support eventually got dropped by devel/gvfs, leaving only UDisks compatibility as an option.)

1640508827895.png


And this is excellent news, because that single strategically placed ~8000 line gem of a project has not only successfully replaced Linux's 40000+ line udisks2 project, but also saved us from needing systemd, and works with most of our storage technologies and filesystems including ZFS (which udisks doesn't have on Linux), by exporting compatible interfaces to our technologies, so upstream versions of desktops and applications fully work, unmodified:

1640507057758.png




Now yes, bsdisks probably still has some bugs, and exposes bugs in other software and areas of the storage/filesystem stack. But I am devoted to its success, and will work tirelessly to fix what I can. We deserve a state of the art desktop experience on FreeBSD - and bsdisks is a giant leap forward towards it. Please report all the bugs you find, and join its development if you can.
 

grahamperrin

Son of Beastie

Reaction score: 1,022
Messages: 3,440

dj015 big thanks.

I forgot, FreeBSD bug 253149 – sysutils/bsdisks occasionally crashing (signal 11 (core dumped)) (closed), I do still get occasional crashes. I'll continue there.



I look forward to what's described at <https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254024#c15>. I assume that it's partially blocked by issues on the lsof side.


In the meantime I continue to (lazily) pkill gvfsd-trash whenever it prevents unmount at sleep/suspend time.
 
OP
bsduck

bsduck

Well-Known Member

Reaction score: 279
Messages: 303

Thank you dj015 for this great explanation.

My experiences with bsdisks are about one year old, so it definitely wasn't the current version, probably 0.24. I didn't try to use automounting since then, except to reproduce the exFAT issue, before opening the bug report. I'll try extensively again.

We deserve a state of the art desktop experience on FreeBSD
That's something I like to read :)
 

mr8ash

Member

Reaction score: 4
Messages: 23

i had almost the same experience using bdisks when i tried to unmount it using dolphin with i3-gaps as window manager. i had to do fsck on my external hd. i always use automount in the base, What i did was i used vermadden automount_devd.conf, but i edited /usr/local/sbin/automount to /usr/sbin/automount. my automount .conf consist of USERUMOUNT=YES. and for auto_master is /net -hosts -nobrowse,nosuid,intr /media -media -nosuid,noatime,autoro. My external media get mounted or unmounted automatically
 

grahamperrin

Son of Beastie

Reaction score: 1,022
Messages: 3,440

From the manual page:

… The daemon is usually started by D-Bus daemon using its auto-activation feature, thus no rc script is required. …

dj015 please, what's the normal way of restarting the daemon following a crash?

Alternatively: if I want to start the debug-enabled build following a crash – with a view to reproducing the crash and then using gdb(1) with the .core file – how best to start it?

In what types of situation might --debug-devd be useful?

 
Top