LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
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 04-28-2008, 09:35 AM   #1
austinium
Member
 
Registered: Nov 2007
Location: India
Distribution: Debian Stable, Debian Testing
Posts: 209

Rep: Reputation: 27
enabling read write access for non root users


Hi,
I have been trying to enable read-write access to non-root users(me, when iam not using root)on FAT partitions on my BOSS Linux machine without much success so far. Heres what my fstab file looks like:
-------------------------------------------------------
# /etc/fstab: static file system information.
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc defaults 0 0
/dev/hdd8 / ext3 defaults,errors=remount-ro 0 1
/dev/hdd4 /home ext3 defaults 0 2
/dev/hdb6 none swap sw 0 0
/dev/hdd7 none swap sw 0 0
/dev/hda /media/cdrom0 udf,iso9660 user,noauto 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto 0 0
usbfs /proc/bus/usb usbfs defaults,devmode=0666 0 0
# Added by BOSS
/dev/hdb1 /mnt/disk[hdb1] ntfs noauto,users,exec,rw,umask=000,uid=root,gid=root 0 0
# Added by BOSS
/dev/hdb2 /mnt/disk[hdb2] auto noauto,users,exec 0 0
# Added by BOSS
/dev/hdb4 /mnt/disk[hdb4] vfat noauto,users,exec,umask=000,uid=root,gid=root 0 0
# Added by BOSS
/dev/hdb5 /mnt/disk[hdb5] vfat noauto,users,exec,umask=000,uid=root,gid=root 0 0
# Added by BOSS
/dev/hdd1 /mnt/disk[hdd1] vfat noauto,users,exec,umask=000,uid=root,gid=root 0 0
# Added by BOSS
/dev/hdd3 /mnt/disk[hdd3] vfat noauto,users,exec,umask=000,uid=root,gid=root 0 0
# Added by BOSS
/dev/hdd5 /mnt/disk[hdd5] vfat noauto,users,exec,umask=000,uid=root,gid=root 0 0
# Added by BOSS
/dev/hdd6 /mnt/disk[hdd6] ext3 noauto,users,exec 0 0
-------------------------------------------------------

The ntfs partition doesn't allow rw but thts ok with me, its the FAT partitions that I am trying to setup read write access for. Any help would be greatly appreciated

Thanks
 
Old 04-28-2008, 10:05 AM   #2
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,310

Rep: Reputation: 139Reputation: 139
Try replacing this on all your FAT partition entries:

vfat noauto,users,exec,umask=000,uid=root,gid=root 0 0

with this:

vfat users,noauto,umask=0,iocharset=utf8 0 0
 
Old 04-28-2008, 12:10 PM   #3
jay73
Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 130Reputation: 130
umask=0002 should be a little safer although the safe thing would be not to use any FAT at all.

I believe you can add all your users to a new group and use that as the argument to gid after giving it group write access (chmod g+w).

Last edited by jay73; 04-28-2008 at 12:11 PM.
 
Old 04-29-2008, 05:59 AM   #4
austinium
Member
 
Registered: Nov 2007
Location: India
Distribution: Debian Stable, Debian Testing
Posts: 209

Original Poster
Rep: Reputation: 27
Quote:
Originally Posted by kilgoretrout View Post
Try replacing this on all your FAT partition entries:

vfat noauto,users,exec,umask=000,uid=root,gid=root 0 0

with this:

vfat users,noauto,umask=0,iocharset=utf8 0 0
Hi,
thank you, kilgoretrout and jay73.
it didnt work, fstab is generated automatically at startup (?), so the changes i made got erased after reboot,i did try to umount and mount the FAT partitions after adding making those changes, but that didnt work either
 
Old 04-29-2008, 06:14 PM   #5
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,310

Rep: Reputation: 139Reputation: 139
It must be your udev rules rewriting fstab. I'm not familiar with your distro but given the entries it looks like mount points may be autogenerated at mount by udev as well. Try this for one of your FAT partitions, say hdb4. Make a permanent mount point for hdb4 at /mnt/win_d:

$ su
<enter root password>
# mkdir /mnt/win_d

then replace the hdb4 fstab entry with:

/dev/hdb4 /mnt/win_d vfat users,noauto,umask=0,iocharset=utf8 0 0

Then mount hdb4 from a console as an ordinary user:

$ mount /dev/hdb4

Check and see if you can write to hdb4 by going to /mnt/win_d and creating a file. If it works, try rebooting and see if the hdb4 fstab entry survives.
 
Old 04-30-2008, 02:08 AM   #6
austinium
Member
 
Registered: Nov 2007
Location: India
Distribution: Debian Stable, Debian Testing
Posts: 209

Original Poster
Rep: Reputation: 27
:)

thanks kilgoretrout,

It worked, but now at start up i see a message which goes like "utf8 is not a recommended IO charset for FATfilesystems, filesystem will be case sensitive!" is there a way to avoid this???

BOSS Linux is a Debian based distribution(Kernel 2.6.21).

Last edited by austinium; 04-30-2008 at 02:14 AM. Reason: Distribution
 
Old 04-30-2008, 09:50 AM   #7
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,310

Rep: Reputation: 139Reputation: 139
That can be eliminated by dropping "iocharset=utf8" from your fstab entry which would leave it like so:

/dev/hdb4 /mnt/win_d vfat users,noauto,umask=0 0 0

That should be more consistent with the BOSS setup as it apparrently doesn't like UTF.
 
Old 05-01-2008, 07:05 AM   #8
austinium
Member
 
Registered: Nov 2007
Location: India
Distribution: Debian Stable, Debian Testing
Posts: 209

Original Poster
Rep: Reputation: 27
hi,

this is what the FAT partitions i have rw access to have their entries as in fstab

/dev/hdd1 /mnt/disk[hdd1] vfat umask=000 0 0
/dev/hdd3 /mnt/disk[hdd3] vfat umask=000 0 0
/dev/hdd5 /mnt/disk[hdd5] vfat umask=000 0 0
/dev/hdb4 /mnt/disk[hdb4] vfat umask=000 0 0

The error messages arent't popping up anymore. So far so good. Hope this doesnt increase the risk(if any) of messing up my FAT partitions!

Thanks for helping out.
 
  


Reply

Tags
fstab, linux


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
how to give all users read/write access to a file in the Firefox profile folder 7trek Fedora 2 11-25-2007 05:09 PM
Allowing normal users read-write access to Windows partitions Aphex_Twin2 Slackware 5 05-23-2005 09:22 AM
Read and write USB device with non-root access halfzware_shag Linux - Hardware 3 10-11-2004 04:26 AM
NFS non root read write access matthewkeen Linux - Networking 8 09-09-2004 10:52 PM
need multiple users to have read/write access to a Quickbooks file at the same time. rbelknap Linux - Security 2 10-14-2003 10:52 PM


All times are GMT -5. The time now is 07:35 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