LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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!

Notices

Reply
 
Search this Thread
Old 07-01-2006, 09:07 PM   #1
JulienPDX
Member
 
Registered: Mar 2005
Location: Corvallis, OR USA
Distribution: Ubuntu 6.01 Dapper Drake
Posts: 57

Rep: Reputation: 15
Post NTFS mounts; but I can't read it


hi!

quick question. I can successfully mount NTFS volumes ( I have two external hard drives that use USB to connect).

FedoraCore5 sees it and mounts but I have to be in as root to read the files on there, how can I change that?

Thanks
 
Old 07-01-2006, 09:33 PM   #2
DeusExLinux
Member
 
Registered: May 2004
Location: Tampa, Fl
Distribution: Arch
Posts: 648

Rep: Reputation: 30
How are you mounting them?

What are the contents of your /etc/fstab? As well as any other various good files.
 
Old 07-02-2006, 12:56 AM   #3
JulienPDX
Member
 
Registered: Mar 2005
Location: Corvallis, OR USA
Distribution: Ubuntu 6.01 Dapper Drake
Posts: 57

Original Poster
Rep: Reputation: 15
mounting

i'm mounting this drive by plugging it in. Its a USB external hard drive. The system auto-mounts it upon plug in; but i'm not able to read the contents unless i'm using a root file browsing process. I imagine this is prob. some security issue but how can i manually change the permissions of the volume?

And not just the volume; but all contents too. I have noticed that changing perms on a directory seems to not ever include contents,.
 
Old 07-02-2006, 01:15 AM   #4
binary_y2k2
Member
 
Registered: Jul 2005
Location: England, UK
Distribution: Ubuntu 8.04 Server, Kubuntu 12.04
Posts: 698
Blog Entries: 1

Rep: Reputation: 31
you need to edit /etc/fstab to include the option "user", eg
Code:
/dev/sda1 /mnt/sda1 auto ro,user,noauto 0 0
if sda1 is the usb device

And it's not a good idea to try to change permissions on a NTFS mount as 1st there is no write access and 2nd NTFS dosen't support linux file permissions.

Last edited by binary_y2k2; 07-02-2006 at 01:17 AM.
 
Old 07-02-2006, 03:27 AM   #5
JulienPDX
Member
 
Registered: Mar 2005
Location: Corvallis, OR USA
Distribution: Ubuntu 6.01 Dapper Drake
Posts: 57

Original Poster
Rep: Reputation: 15
confused

i dont know if this matters; but i'm using fedora core 5.

When I ls the /mnt directory (as root) nothing shows up.

also, there is a file called /etc/fstab and i can open it in a text editor; but i don't see a reference to the device.
 
Old 07-02-2006, 03:34 AM   #6
binary_y2k2
Member
 
Registered: Jul 2005
Location: England, UK
Distribution: Ubuntu 8.04 Server, Kubuntu 12.04
Posts: 698
Blog Entries: 1

Rep: Reputation: 31
the /mnt dir can be replaced by any dir, it's just the mount point, if there is no reference to your usb HDD then you should add it in there using my example a a template.
you should look at "man fstab" and "man mount" especially the section on "Mount options for ntfs" in man mount.
 
Old 07-02-2006, 03:49 AM   #7
JulienPDX
Member
 
Registered: Mar 2005
Location: Corvallis, OR USA
Distribution: Ubuntu 6.01 Dapper Drake
Posts: 57

Original Poster
Rep: Reputation: 15
okay okay; i found out that indeed, the location of the device is dev/sda1 *as you said*; however if i add the line in my fstab as you suggested; the drive doens't show up when I reboot. I then unplug the drive and plug it back in and i get a message in Gnome indicating that I dont have priveleges to mount LACIE (the name of the external drive) grrr.
 
Old 07-02-2006, 03:52 AM   #8
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
It's not showing up when you reboot because of the noauto option. If you want it automatically mounted when you boot, then change "noauto" to "auto".
 
Old 07-02-2006, 03:54 AM   #9
binary_y2k2
Member
 
Registered: Jul 2005
Location: England, UK
Distribution: Ubuntu 8.04 Server, Kubuntu 12.04
Posts: 698
Blog Entries: 1

Rep: Reputation: 31
that's if it's always inserted, yes. if not you'll get a small error saying "/dev/sda1 not found..." or somethin like that
 
Old 07-02-2006, 04:05 AM   #10
JulienPDX
Member
 
Registered: Mar 2005
Location: Corvallis, OR USA
Distribution: Ubuntu 6.01 Dapper Drake
Posts: 57

Original Poster
Rep: Reputation: 15
still not working

if file is edited as stated:

/dev/sda1 /mnt/sda1 auto ro,user,noauto 0 0

drive doesn't show up on boot-up; gives me "don't have permissions to mount" error when unplugged and plugged back in; within gnome.

or

/dev/sda1 /mnt/sda1 auto ro,user,auto 0 0
during boot (before going into X); there is a line that says something to the effect of "attempting to mount other filesystems; /mnt/sda1 does not exist" drive won't show up on desktop in Gnome; unplugging and replugging it in gives me same error as above (no permission to mount)

If /dev/sda1 /mnt/sda1 auto ro,user,(no)auto 0 0 IS NOT included in fstab; drive shows up on gnome desktop upon bootup but can't be browsed.
 
Old 07-02-2006, 04:08 AM   #11
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655
Do you see a reference to "usbfs" or something similar in your /etc/fstab file. Your system may use a hotplug script, or UDEV to mount usb drives when they are plugged in. If you monitor the logs when inserting the usb drive, what message shows up: "sudo tail -f /var/log/messages".

Check for a /etc/udev/rules.d/ directory. Grep for "sd\*".
On my system, the rules are:
Code:
jschiwal@hpamd64:/etc/udev/rules.d> grep -n 'sd\*' *
60-persistent-storage.rules:23:KERNEL=="sd*[!0-9]|sr*|st*", ENV{ID_SERIAL}=="", IMPORT{program}="/sbin/usb_id -x"
60-persistent-storage.rules:24:KERNEL=="sd*[!0-9]|sr*|st*", ENV{ID_SERIAL}=="", IMPORT{program}="/sbin/scsi_id -g -x -s %p -d $tempnode"
60-persistent-storage.rules:25:KERNEL=="sd*[!0-9]|sr*|st*", ENV{ID_SERIAL}=="", IMPORT{program}="/sbin/scsi_id -g -x -a -s %p -d $tempnode"
60-persistent-storage.rules:27:KERNEL=="sd*[!0-9]|sr*|dasd*[!0-9]", ENV{ID_SERIAL}=="?*", SYMLINK+="disk/by-id/$env{ID_BUS}-$env{ID_SERIAL}"
SYMLINK+="disk/by-id/$env{ID_BUS}-$env{ID_SERIAL}-part%n"
85-mount-fstab.rules:2:SUBSYSTEM=="block", ACTION=="add", KERNEL=="sd*[0-9]|hd*[0-9]", RUN+="mount.sh"
Here are two LXer syndicated articles that have been featured on this site in the past.
http://www.linuxquestions.org/questi...highlight=udev
http://www.linuxquestions.org/questi...highlight=udev

If the device is created with the group ownership of "disk", a shortcut could be to make yourself a member of the "disk" group. However, I don't know whether this is a very proper way of doing it, or maybe even dangerous ( if /dev/sda has "disk" group ownership as well as /dev/sda1 ).

Last edited by jschiwal; 07-02-2006 at 04:12 AM.
 
Old 07-02-2006, 12:23 PM   #12
DeusExLinux
Member
 
Registered: May 2004
Location: Tampa, Fl
Distribution: Arch
Posts: 648

Rep: Reputation: 30
I had a similar problem, for some reason mounting an NFTS volume sometimes requires one extra append to the fstab file.

Try addign this to the end of your /dev/sda1 line:
Code:
umask=0222
 
Old 07-02-2006, 03:37 PM   #13
JulienPDX
Member
 
Registered: Mar 2005
Location: Corvallis, OR USA
Distribution: Ubuntu 6.01 Dapper Drake
Posts: 57

Original Poster
Rep: Reputation: 15
Smile gave up

i gave up; none of those suggestions work for me, so what I started doing is this:

on one of my workspaces i always have a terminal window open; full screen.

I simply become su and then start nautilus in file browsing mode. I am able to read files there, so that is fine with me. Its just the external drive I used to save all my movies, music and documents from my windows installation so that I can see them while using Linux---which is a big need if I'm ever going to switch to this permanently :-)

This still doesn't make me want to go back to windows. <still enjoying the honeymoon) LOL

Btw, my sound card broke. (I had the tower plugged into my stereo and since the cable isn't very long, my tower was pulled out and on the floor so the cable could reach my stereo. I started cleaning my room and stupidly forgot it was still plugged in when I attempted to move it back to the desk. I set the tower on the edge of the bottom shelf of my desk and it kinda dropped and it bent the 3.5 plug while it was still plugged into the card. A big piece of the actual "ring" that the plug goes into *the green ring* then came off when I unplugged the cable. Now, any time I have any speaker plugged into the card; I have to jiggle it and hold it to make contact.

I was going to attempt to use super glue today--but, we have like a bunch of unopened soundblasters at work that we never used (exact same model as the one i've now had for 6 years-SBLive5.1) so I will probably just snag one of those. Also, my motherboard has onboard audio (that I had never used). So I simply took out the soundcard and then activated the onboard audio.

I was shocked and suprised and happy that my distro automatically detected this change and installed whatever driver was needed to use the onboard audio :-)))))

Last edited by JulienPDX; 07-02-2006 at 03:41 PM.
 
Old 07-02-2006, 04:03 PM   #14
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655
You may want to make yourself a member of the "wheel" group. Then run "visudo" and remove the "# " comment characters in the sudoers entry "# %wheel ALL=(ALL) ALL". This will allow you to run root commands like mount by preceding the commands with the command "sudo ".

In your /etc/fstab file, you can add an entry for your usb drive (/dev/sda1).
Do not use the option "auto". Your commputer will fail to boot if the usb drive isn't plugged in.
I would recommend that you either use the option "umask=0000" or make yourself the owner with the option "uid=<yourusername>". The "users" option will allow you to use umount or eject.

Here is the fstab entry for an ntfs partition on my laptop:
/dev/hda1 /windows/C ntfs ro,users,uid=jschiwal,gid=users,umask=0002,nls=utf8 0 0

For an external drive, I would add the option "noauto" to prevent the system from locking up when you boot up the computer. Use the uid and gid values for your own system. If you use them, you don't need the umask= option if you are the only user who needs access to the drive.
 
  


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
nfs mounts read permissions Tinku Linux - General 5 01-26-2006 02:54 AM
access NTFS mounts without root btaber Linux - Hardware 4 03-23-2004 05:05 PM
FAT mounts read-only jogurt666 Linux - General 3 02-12-2004 07:13 AM
Compiled RH7.3 to read WinXP NTFS partition, mounts in Console, but can't mount fstab BlackDogg Linux - Newbie 20 08-06-2002 12:15 AM
Bad FAT... re-mounts to read only. sourceman Linux - General 1 02-11-2002 12:10 PM


All times are GMT -5. The time now is 01:50 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration