Make. Automount. Stop.

Latest response

Every article on automount that I see is about getting it to work. I want it to sit down and shut up, and have administrators manually mount USB devices, no exceptions. How does one do that?

Responses

Well, if you do something like echo "blacklist usb-storage" > /etc/modprobe.d/blacklist.conf or even just echo "install usb-storage /bin/true" > /etc/modprobe.d/usb.conf(and then reboot), that would take care of things for you.

Similarly, if you're using the graphical desktop, you could use the gconftool to disable automated mounting (with the /apps/nautilus/preferences/media_automount false and /apps/nautilus/preferences/media_autorun_never true options).

I tried chmod 700 /media, which did stop automount. But now, despite restoring 755 on that directory, it doesn't automount and I can't see the device (which was formatted as a single file system occupying the entirety of a 4TB LaCie disk).

Is there any like the OpenBSD xconsole to report USB device plugin so that I can see where the disk is to mount it manually?

Changing permissions on the parent mount-point shouldn't really prevent the automated processes from mounting the device (other than possibly for non-privileged users). Depending on your system's security settings, one of the ls tools (lsblk, etc.) should tell you what device the system is seeing the USB device as. At that point, if you've got sufficient permissions, you should be able to manually mount the device (e.g., mount -t vfat /dev/XXXX /mount/point).

Another option is using "Disks" in GNOME 3 (Utilities -> Disks) to manage the mounting options. I did that ages ago when I got tired of my stack of USB 2TB HDDs were wasting time getting mounted at login.

The package name is:

gnome-disk-utility-3.14.0-2.el7.x86_64 : Disks
Repo        : @rhel-7-desktop-rpms
Matched from:
Filename    : /usr/bin/gnome-disks

Thanks, I'll take a whack at that.

The automount is always a proponent feature of the desktop system; kde, gnome, xfce etc.

Changing the modprobe blacklist temporarily fixed the visibility problem. Thanks to all.

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.