PDA

View Full Version : don't show bind-mounts in nautilus's "devices" in places-view



Bazon
17th September 2012, 12:57 PM
Summary:
How do I remove folders mounted via bind in /etc/fstab from appearing in nautilus left column, the "places" view?


detailed:
Hello,

I mount various directories from my data partition via bind in /etc/fstab in my home directory, eg like this:



/mnt/sda5/bazon/Bilder /home/Bazon/Bilder none bind 0 0
/mnt/sda5/bazon/Downloads /home/Bazon/Downloads none bind,user 0 0

(Background: /dev/sda5 mounted to /mnt/sda5 is my old home partition, but I do not want to mount it as a home partition, as I always have at least 2 Linuxes on the computer ...)

That works well, but every one of those items is listed in Nautilus in the left column under "Devices". (. Where normally USB drives appear, etc.) This is not just a waste of space, it does not help: Click on it leads to the message (for example :)


mount Bilder not possible
mount: only root can mount / mnt/sda5/bazon/Bilder on /home/Bazon/Bilder
(translated from german message)


This error message can be prevented with the mount option "user" (see above under "Downloads"), but clicking on that entry under "Devices" in Nautilus then leads to exactly nothing, the directory is not opened. (Although the mount itself works if you follow the path.)

Therefore, I would prefer to simply hide these bind mounts. How does it work?
Thanks in advance!