MEPIS This forum is for the discussion of MEPIS Linux. |
Notices |
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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
05-16-2007, 07:41 AM
|
#1
|
Member
Registered: Jan 2006
Distribution: Gentoo
Posts: 507
Rep:
|
How to mount pendrive from terminal???
Hello.
As you can see in the subject field, I am asking how to mount my USB pendrive form a terminal? I know that Mepis has an automount feature for such devices, but I created a user profile for my mom, and I didn't give mount rights for her. To be clear, I don't want to give mount rights for her. This user profile also works as an internet browsing profile too, so this little restriction makes the system more secure (there are some personal data on other partitions). So: the automount function doesn't work any more. I tried the mount command, but it says there is no such device or it is not in the fstab. I tried the mount command of course as root. Some months ago I was given an advice not to add entries for pendrives into the fstab, so I didn't add anything. So, my question: how to mount my pendrive from console (using root mode), without adding mount permissions to user profile, without adding anything to fstab and without typing kilometer long commands? Thanks for reading, and trying to answer.
|
|
|
05-16-2007, 08:21 AM
|
#2
|
ReliaFree Maintainer
Registered: Aug 2004
Location: Kalamazoo, Michigan
Distribution: Slackware 14.2
Posts: 2,815
|
Assume the pendrive is /dev/sda1 and you want to mount it at /media/pendrive, then you should be able to mount it as a priveleged user with
Code:
mount /dev/sda1 /media/pendrive
There is a wrapper called pmount that, IIRC, the Debian folks created to allow non-priveleged users to mount things such as pendrives. This might be something you want to install for mom. If you use pmount, the command would be
Code:
pmount /dev/sda1 /media/pendrive
Additionally, you might want to create and alias so mom doesn't need to type so much
Code:
alias pen='mount /dev/sda1 /media/pendrive'
Then mom just executes the command pen to mount the pendrive.
|
|
|
05-16-2007, 08:23 AM
|
#3
|
LQ Guru
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852
|
Assuming the device is sda1 (which it should be if you are using IDE drives and it is a standard format flash drive) you would do:
Code:
sudo mount /dev/sda1 /mnt/mountpoint
Where mountpoint is the actual directory you want to mount it to. You can either use one of the existing ones, or just create a new directory.
|
|
|
05-16-2007, 08:53 AM
|
#4
|
Member
Registered: Mar 2007
Location: North Carolina
Distribution: Slackware 12.0, Gentoo, LFS, Debian, Kubuntu.
Posts: 906
Rep:
|
Could write a udev rule.
Could read writing udev rules and allow her to mount that one particular pen drive . thats what i do for my wife and debian auto mounts it but she can't mount anything else (like my usb drive) and i can't mount hers. The beauty of this is limiting access but still allowing the automount features.
edit
Think mounting is something like:
sudo mount -t vfat /dev/sda1 /mnt/mountpoint
just make sure the mountpoint exist. this should work if you don't want a fstab entry.
Last edited by Hern_28; 05-16-2007 at 09:03 AM.
|
|
|
05-16-2007, 11:55 AM
|
#5
|
Member
Registered: Jan 2006
Distribution: Gentoo
Posts: 507
Original Poster
Rep:
|
Thanks!
Thanks Guys!
That method of Arow is extremely helpful. Thanks! I didn't know about that pmount prog, but now I do . Everything just works fine now.
|
|
|
All times are GMT -5. The time now is 12:03 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|