You are not logged in.
Gnome always mounts my Windows partitions to /media. I have shut off all automount options in the gnome-volume-manager, but it still mounts them all. They are ofcourse not listed in my /etc/fstab. Is this supposed to be some kind of "feature"?
Does anyone know how I can fix this annoying behaviour?
Offline
This may help you. Look for where he talks about elective mount point: http://kmandla.wordpress.com/2008/03/17 … istro-nfs/.
Offline
I was thinking about that before, but I hadn't tried it yet because it seems a bit like a dirty hack method to get rid of this behaviour. But I can say, it does work! I added the partitions to fstab with the noauto option and they have stopped appearing on my desktop for now. Thanks for the link.
Still, I find it odd there isn't an easier way to accomplish this?
Offline
maybe add it to fstab with the noauto option? hal mounts everything that's not in the fstab...
Offline
maybe add it to fstab with the noauto option? hal mounts everything that's not in the fstab...
You are right !
I have had the same problem as you and here is the solution :
Define a mount point in /etc/fstab for your volumes which is not in /media. gnome-volume-manger will mount every thing which is either not in /etc/fstab (through hal) or which has a mount point in /media.
Also use the option 'noauto' in /etc/fstab for that mount point to make sure the init process will not mount it at boot.
You might have a line like this in /etc/fstab :
/dev/sda1 /mnt/mywindows ntfs-3g defaults,noauto 0 0
where /dev/sda1 is your windows partition. You might also use UUIDs (see http://wiki.archlinux.org/index.php/Per … ce_naming)
I hope it helped !
Offline
Yes, that's what I did and it works, but like I said, it's kind of a dirty method to accomplish this. Because after all, I'm never ever going to mount these drives anyway, so it's rather silly that they have to be in my fstab. There has to be a simpler way of telling gnome-volume-manager not to mount these fixed partitions.
Offline
There is a "cleaner" way, as long as you consider this method as a dirty one which I do not . I guess it is a mater of choice ...
You can disable the mounting of a given partion inside hal configuration.
See :
http://wiki.archlinux.org/index.php/HAL
http://people.freedesktop.org/~david/ha … -spec.html
I did not want to go deeper into hal configuration, but I would be interested to know if you succeed this way and how you did it
Offline
That actually worked! Thanks! But the partitions still show up in Nautilus and the Places menu though. I had a look at the HAL policies in the link you provided and I noticed the "volume.ignore" policy. If I can figure out how to implement that, it might work to not show the partitions anywhere at all.
Offline
Okay, I managed to make it so they do not show up anywhere, here is my preferences.fdi file located in /etc/hal/fdi/policy/:
<?xml version="1.0" encoding="UTF-8"?>
<deviceinfo version="0.2">
<device>
<match key="storage.hotpluggable" bool="false">
<match key="storage.removable" bool="false">
<merge key="storage.automount_enabled_hint" type="bool">false</merge>
</match>
</match>
</device>
<device>
<match key="volume.uuid" string="2E2C05502C05150D">
<merge key="volume.ignore" type="bool">true</merge>
</match>
<match key="volume.uuid" string="afba1791-11b8-496d-a232-04805eaef6b2">
<merge key="volume.ignore" type="bool">true</merge>
</match>
</device>
</deviceinfo>
Technically, the "storage.automount_enabled_hint" is not needed anymore, but it's not a bad thing to have it there.
I use UUID's to address my partitions, and that's pretty straight forward with the "volume.uuid" key, but for the people who want to use the normal partition names, I don't really know how that would work. There is a "volume.partition.number" key, but that only accepts a integer, and not a string like "sda6" for example.
You can find the UUID's of your partitions in /dev/disk/by-uuid/. Just do ls -l.
Thanks for all the help. One step closer to a perfect Arch system
Last edited by HyperBaton (2008-04-18 11:56:05)
Offline
Glad you succeeded, and thank you for posting the hal solution !
This is why i like Arch : you learn how the low level layers work (not the GUI frontend). Thus what you learn can be applied on any other distro
Offline
One thing that I don't understand is this though: Until a few days ago, I was using XFCE and I never had this "problem" there. My partitions were not automounted to /media and didn't show up on the Desktop. But HAL is HAL, whether it's XFCE or Gnome, it shouldn't matter. So does that mean I can conclude that it's gnome-volume-manager that's the cause of this and not HAL?
Offline
I am not 100% sure but I think gnome-volume-manager is responsible for this.
I even had a different behavior in Gnome 2.20 and Gnome 2.22 (where they migrated to GIO/GVFS)
Offline
So, does this solution prevent USB flash drives from automounting or just the fixed discs within your system?
Offline
This solution prevents only the discs within your system, and only the discs/partition you excplicitly specify.
For USB stuffs you can configure the behavior (manual mount or auto mount) with the usual Gnome configuration tools : system -> media storage (I do not know the exact name in english, but you will find it )
Offline
System -> Removable Drives and Media
Tick off "Mount removable drives when hotplugged", that's the one you want I think.
Offline
Disable gnome-volume-manager automount;
http://bbs.archlinux.org/viewtopic.php?id=43384
"Your beliefs can be like fences that surround you.
You must first see them or you will not even realize that you are not free, simply because you will not see beyond the fences.
They will represent the boundaries of your experience."
SETH / Jane Roberts
Offline
Yeah, that works, but with these extra hal policies the hard drives don't show up at all anymore, which is what I was really going for
Offline
actually, afaik gnome-volume-manager doesn't exist anymore, automonting is now done by nautilus or something
Last edited by Phrodo_00 (2008-04-20 03:17:28)
Offline
Yeah, that works, but with these extra hal policies the hard drives don't show up at all anymore, which is what I was really going for smile
My method does work with gnome 2.20 (gvm 2.17), just the way you would like it. Unfortunately gnome-volume-manager does not honor hal's request to disable automount, so that is why you need to patch gnome-volume-manager first.
Apparently, gnome 2.22 (gvm 2.22) honours the hal policy i used with gnome 2.20 (gvm 2.17) without patching gnome-volume-manager at all . I have yet to try that out though.
http://www.nabble.com/GNOME-2.22-has-be … #a16280245
The only other way i know of (without setting a policy in hal telling gvm not to autmount), is by using policykit to do temporary authorizations (like you can in mandriva 2008.1, fedora 9)
"Your beliefs can be like fences that surround you.
You must first see them or you will not even realize that you are not free, simply because you will not see beyond the fences.
They will represent the boundaries of your experience."
SETH / Jane Roberts
Offline