When I (manually) mount my crypted document partition on ubuntu 19/04, it is mounted on /media. When I'm in Fedora, it's mounted on /run/media.

I would like udisks2 to mount it on /run/media, as it should be, so I made a udev rules like this :

# cat /etc/udev/rules.d/99-udisk2.rules 

# ==1: mount filesystem to a shared directory (/media/VolumeName)
# ==0: mount filesystem to a private directory (/run/media/$USER/VolumeName)
# See udisks(8)
ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{UDISKS_FILESYSTEM_SHARED}="0"

But, even after reboot, the document parition is still mounted on /media. Can someone help me to mount it on /run/media ?


Well, it is a source building option as mentioned by this commit when it was introduced.

Support mounting in /media for FHS compatibility

Add --enable-fhs-media configure option to mount in /media instead of /run/media, for FHS compliance and backwards compatibility.

Options I could think of:

  • Make a symlink
  • Bind mount
  • Rebuild the package
| improve this answer | |
  • Can it be configured somewhere in configuration file or I must re-compile the package? – Anwar Jun 27 '19 at 8:34
  • 1
    @Anwar, Unfortunately, that configuration is compile time option. So you have to recompile if you want change it without workarounds. – user.dz Jul 3 '19 at 21:10
  • 1
    Yes. I recompiled and worked accordingly – Anwar Jul 4 '19 at 10:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.