not able to write to vfat partition with non-root id
FedoraThis forum is for the discussion of the Fedora Project.
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.
not able to write to vfat partition with non-root id
Hi All,
I have FC5 installed on my Dell Inspiron 1300. I have a FAT32 partitions which I want to share between windows and linux. From linu, I am able to read and write on FAT32 partition with root userid, but not with anyother userid. If I try to write from anyother user id I get error "Permission denied". Please let me know how to make it writable for other users. I tried to change the permission for the direcotries but no luck, I am not able to do so.
Thanks in advance,
Last edited by rajeev1982; 08-03-2006 at 06:34 AM.
One could use umask= in place of uid= too, but if uid= works, it might be better stick with it. I've only used umask= so I can't tell the exact difference between these two..
Since you have few posts and maybe kind of new at linux, I won't assume that you realize the obvious for me.
In the example that was given, they used the partition of /dev/hda2 and a folder called /mnt/fat. You need to make any changes to work for your system.
For example, I made a vfat partition /dev/sda6 and a folder called /mnt/test
Redhat / Fedora makes the first user with user id of 500 and group id of 500 . You can verify that by running the id command:
For example: id fred
uid=500(fred) gid=500(fred) groups=500(fred)
If you want more users to access the vfat partition, it's easiest to make them part of the same group when they are created.
For example: useradd -g 500 tim
Now, as root user, I can add an entry in /etc/fstab.
Code:
To make it writable for users with a group id of 500, edit the /etc/fstab file to include the following line.
/dev/sda6 /mnt/test vfat gid=500,umask=002 0 0
To make complete control for users with a group id of 500, try something like this in the fstab....
/dev/sda6 /mnt/test vfat gid=500,umask=000 1 0
To give one user complete control of that directory, try something like this in the fstab....
/dev/sda6 /mnt/test vfat uid=500,gid=500,umask=000 1 0
Don't forget, those are examples and you need to use the correct partition name and folder name.
One thing you might want to do is run a chkdsk <drive:> /f on your FAT32 partition in Windows. I seem to remember that fixing the same problem I once had.
I think the equivalent linux command is: fsck.vfat -a <partition>.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.