LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   non-root user cannot access Windows partition (https://www.linuxquestions.org/questions/linux-general-1/non-root-user-cannot-access-windows-partition-217256/)

curmudgeon42 08-13-2004 03:07 PM

non-root user cannot access Windows partition
 
i have a dual-boot Gentoo and Windows XP computer. one of the partitions on my harddrive, /dev/hda7, is a Fat32 partition created by WinXP. my goal is to have that partiion be a location for shared data between the OSes (firefox bookmarks, thunderbird mail, documents, etc.)

my /etc/fstab has this entry:

/dev/hda7 /mnt/win_f vfat noatime 0 1

this seems to work in that when the system boots up, if i su to root, i can see the contents of that partition

however, if i am not su'ed, but logged in as my normal desktop user, i cannot access that drive.

here is the permissions on /mnt/win_f

drwxr--r-- 8 root root 16384 Jan 1 1970 win_f

i tried to change the permissions but it seemed unsuccessful. how do i allow this non-root user to access this partition? does that user have to be a member of a group or something that I didn't give it access to?

thanks,

~ Justin

b0uncer 08-13-2004 03:22 PM

hmm...you could try adding the word "user" (or "users" possibly..."user" should do) to the fstab options section:

/dev/hda7 /mnt/win_f vfat user,noatime 0 1

I don't guarantee this works, but basically it should allow normal users access that too. don't shoot me if it doesn't help you :)

sharper 08-13-2004 03:44 PM

The default for NTFS is accesable by root only. For others to access it I had to add a umask= to the line in /etc/fstab. I currently have umask=777, which is probably not the most secure, but it works.

curmudgeon42 08-13-2004 04:33 PM

after a good ol' session of RTFM, i ended up with the following in fstab which seems to work (in a very unsecure way but this is only a desktop):

/dev/hda7 /mnt/win_f vfat auto,umask=000 0 1

now when i boot my normal user can go to /mnt/win_f and read/write without doing anything else first, which is exactly what i want

it seems that the umask is opposite of the bits for chmod, so counterintuitively 000 means access for all

thanks for the help,

~ Justin


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