Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to get fstab to auto-mount a removable device when its plugged in? Is this possible and if not what is the easiest way to auto-mount a removable device?

share|improve this question

migrated from stackoverflow.com Feb 23 '10 at 19:52

This question came from our site for professional and enthusiast programmers.

1  
related automounting questions: superuser.com/questions/16823/… .. superuser.com/questions/53978/… –  quack quixote Feb 24 '10 at 1:35

2 Answers 2

up vote 1 down vote accepted

You will need some kind of automounter. That will largely depend on what Linux distribution you have and whether or not you're using a GUI or CLI based system. And then, it will also depend on whether or not your using Gnome or KDE as your desktop environment. My experience lies with Gnome on Gentoo, Ubuntu and a little experience with Redhat. But you won't be able to use fstab to automatically mount devices when they're plugged in or removed.

share|improve this answer
    
this is correct; /etc/fstab is not used for automounting hotplugged devices. –  quack quixote Feb 24 '10 at 1:34

While you many not be able to use fstab, you will be able to set up automount with udev and hal. However, in my experience (KDE, Gnome, and XCFE) Desktop Environments will automatically mount most removable devices.

share|improve this answer
1  
i posted a lengthy how-to-automount-with-udev answer here: superuser.com/questions/53978/… .. there's also a HAL-based solution with HALevt in another answer below that one. you're right that most desktop environments provide their own automounter. –  quack quixote Feb 24 '10 at 1:40

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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