Where are the options for automounted USB drives or how is automounting done in Ubuntu 20.04

ar flag

In Ubuntu 20.04 (as in previous versions), external USB drives are automatically mounted when they are plugged in, and an icon for each partition appears in the Dock.

How is that working? Which services take care of that, and where do they get the details for their configuration?

In particular, I would like to change mount options for NTFS and HFS+ partitions.

There are several similar questions, but they seem more focused on specific drives, and the answers send to /etc/fstab, or using the Disks utility (gnome-disk-utility) to edit options which will only apply to one specific drive or partition.

The AutomaticallyMountPartitions page mentions udisks, but only shows how to use it interactively and doesn't describe how it interacts with the other parts.

I can also find udev rules with scripts to automount partitions, but the system already does that.

Jad avatar
br flag
have you looked at or ?
ar flag
@Jad: unfortunately, nothing new in these pages. And, yes, I had already installed dconf-editor to look for settings there, but that didn't help either.
cn flag

You can provide specific mount options for automatically mounted partitions in a file /etc/udisks2/mount_options.conf. For example, one could set options for a specific drive as:


See /etc/udisks2/mount_options.conf.example for details and examples on how changes can be changed, globally or for specific drives and/or file systems.

nobody avatar
gh flag
Are you sure you were looking on ubuntu 20.04? Can't find `/etc/udisks2/mount_options.conf.example` ^^
vanadium avatar
cn flag
No, I only have Ubuntu 21.10. I will leave the answer up for future users.

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.