LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 11-13-2005, 03:23 PM   #1
rrrssssss
Member
 
Registered: Mar 2005
Posts: 284

Rep: Reputation: 33
USB HD Needs Root Privileges


Hello Forum,

I have just installed Mandriva Linux 2006 on a freshly formatted partition but one of my USB hard drives will not open unless it has root privileges. The other USB hard drive opens fine.

How can I change the first USB hard drive to open without giving it root privileges?

Thanks in advance,
Roy
 
Old 11-13-2005, 03:37 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975
can you explain what you're actually doing for these actions? it makes no sense to say you need to give a usb device root priveledges... a device doesn't have priveledges, the processes or users accessing it do.
 
Old 11-13-2005, 03:59 PM   #3
rrrssssss
Member
 
Registered: Mar 2005
Posts: 284

Original Poster
Rep: Reputation: 33
I can't access the first USB hard drive unless I have root privileges. I want to be able to access that hard drive without giving myself root privileges.

Roy
 
Old 11-13-2005, 04:08 PM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975Reputation: 1975
ok, well USB drives can be messy cos they can jump around in the device names they are given. if you find that it's only the second one you plug in that requires those permissions or something, then you can probably get away with a simple /etc/fstab entry like the existing one (assuming there is one), e.g.

/dev/sdb1 /mnt/usb_hd2 auto 0 0

i.e. rather than it being sda, which is used by an exisiting connected device, it gets the next in the list, sdb.

This is a bit crude though. if you want a more formal solution, you'd want to look into writing your own udev rules, which can help you directly identify what device you have plugged in and place it in a suitable location. for example you can take the maker of the drive. say you have one maxtor, one seagate. if the vendor is found to be maxtor then you can explicitly tell idev to ALWAYS place that device at /dev/usb_maxtor as opposed to /dev/usb_seagate. this is only one example though, you could use all sorts of things to keep them being connected to a reliable location. And of course when it IS in that reliable location, it' smuch saner to have an /etc/fstab directory for each device you use an any frequent basis.

try this: http://www.reactivated.net/writing_udev_rules.html
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Root privileges for user ar1 Linux - Security 2 01-07-2005 09:33 PM
How to mount without root privileges? ni0wn Slackware 3 09-15-2004 05:03 PM
User with root privileges ShakyJake Linux - Newbie 2 06-18-2004 12:12 PM
root privileges and permissions evil_lafta Slackware 7 08-20-2003 09:37 PM
Xine and root privileges markus1982 Linux - Software 1 08-18-2003 03:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:11 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration