Comment 12 for bug 1618370

Revision history for this message
Rocko (rockorequin) wrote :

Ok, I'm pretty certain that https://bug765457.bugzilla-attachments.gnome.org/attachment.cgi?id=327716 (from bug https://bugzilla.gnome.org/show_bug.cgi?id=765457) is the patch that fixes this issue, because I'm looking at nautilus' sidebar right now and my drives show up both after being hotplugged and after a reboot.

There's a lot more info in the upstream bug https://bugzilla.gnome.org/show_bug.cgi?id=770923 (which is now closed as not-a-gnome-bug), but to summarise:

* Gnome modified nautilus v3.22 to (additionally) use the Removable property exposed by udisks2 when deciding to show volumes in the sidebar and Other Locations.

* This required patches to gvfs, glib, gtk+ to support a new function, g_drive_is_removable(). See comment #8 at the upstream bug for the related bugs and patches. It also mentions nautilus but that's only for 'Other Locations', not the sidebar.

* For 3.20, Debian has already backported these patches to glib and gtk+ (and possibly nautilus).

* The only patch missing is the gvfs patch at https://bug765457.bugzilla-attachments.gnome.org/attachment.cgi?id=327716.

* The gvfs patch applies cleanly to Ubuntu's version of gvfs (1.28.2-1ubuntu1), and with it applied, my drive appears in the nautilus sidebar even after reboot.

The only caveat I have is that it took me a while to figure out how to get the patched gfvs daemons running in Ubuntu, as "sudo make install" installs them to /usr/local/lib/libexec, but Ubuntu keeps running the daemons from /usr/lib/gvfs. I eventually found systemd files for the daemons in /usr/lib/systemd/user and modified the gfvs-udisks2-volume-monitor.service to run from /usr/local/libexec. It didn't work after the first reboot, so I changed it back (I commented out my new ExecStart line and restored the old one) and rebooted again. However, something persisted because ps xa now shows that all the gvfs daemons are being run from /usr/local/libexec (and not just the udisks one) and, most importantly, nautilus' sidebar is working fine.

If anyone can tell me how I eventually managed to get the daemons running from the correct place and how to get them working again if Ubuntu changes its mind, that would be fantastic...