Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
What command is executed when you plug in a USB Flash drive manually in the PC's USB port?
I am pluggin in the device and it is automatically getting mounted in /media/ed7a753f-df88-4984-b65a-5d3a8cc2714a. After I unmount the device using umount /media/ed7a753f-df88-4984-b65a-5d3a8cc2714a, how do I remount it from the terminal so that the weird directory gets created automatically and the Flash Drive gets mounted there?
Another question, where does the system get this ed7a753f-df88-4984-b65a-5d3a8cc2714a. Is it some kind of identification of the disk?
The 'ed7a753f-df88-4984-b65a-5d3a8cc2714a' value is from the UUID of the filesystem on the device. On some filesystems you could create a Label for the filesystem and it might be used instead.
If the device node is still present, you could use a simple mount command to mount the device. This may not be the case if you ejected the device.
If your distro has the ivman package installed, you can use `halmount <device>' to automount filesystems via HAL. Here are some examples from the manpage:
list all mountable devices known to hal
mount device hdc on default mount point (/media/volumelabel)
halmount /dev/hdc cdrom
mount device hdc on /media/cdrom
halmount -u "Holiday Pictures"
umount device that has the label "Holiday Pictures"
On most distros automounting removable devices is handled by the desktop environment, and PolicyKit is used behind the scenes to provide permission to do this. On KDE 4 for example, there is a device notifier applet. It can be configured to automount certain devices and ignore others. You wouldn't need to mount the device from the console. I still use halmount however. It is very convenient for mounting and looking up device names.
Well, ivman hasn't had an update in 4 years now, and halevt appears to have been started in response. I was forced to switch over when it stopped working properly on my system, and Debian eventually removed it from its repositories. I guess a few distros just haven't noticed the changeover yet.