Find the answer to your Linux question:
Results 1 to 7 of 7
I am trying to write onto a mounted fat32 partition (Datadisk) in RH 9.0. Only the root has permission to write there as of now. I have tried to use ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Feb 2004
    Posts
    3

    NuB Q: File perm prob


    I am trying to write onto a mounted fat32 partition (Datadisk) in RH 9.0. Only the root has permission to write there as of now. I have tried to use chmod to change file permissions on the mounted partition to allow other users to write there but it returns a error....
    [root@XXX Datadisk]# chmod o=rwx test.txt
    chmod: changing permissions of `test.txt' (requested: 0757, actual: 0755): Operation not permitted


    My fstab looks like
    LABEL=/ / ext3 defaults 1 1
    /dev/hda5 /Datadisk vfat rw 0 0
    none /dev/pts devpts gid=5,mode=620 0 0
    none /proc proc defaults 0 0
    none /dev/shm tmpfs defaults 0 0
    /dev/hda2 swap swap defaults 0 0
    /dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0
    /dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0

    Any ideas?? Thanks in advance.

    DA

  2. #2
    Linux Engineer Giro's Avatar
    Join Date
    Jul 2003
    Location
    England
    Posts
    1,219
    Add user to the options for the drive like so this should allow all users access.
    Code:
    /dev/hda5 /Datadisk vfat user,rw 0 0

  3. #3
    Linux Guru
    Join Date
    Oct 2001
    Location
    Täby, Sweden
    Posts
    7,578
    chmod doesn't work on FAT filesystems since FAT has no storage for the file mode.

  4. #4
    Just Joined!
    Join Date
    Feb 2004
    Posts
    3
    Hi Giro,

    Thanks for the suggestion but it did not help. Now my fstab looks like

    LABEL=/ / ext3 defaults 1 1
    /dev/hda5 /Datadisk vfat user,rw 0 0
    none /dev/pts devpts gid=5,mode=620 0 0
    none /proc proc defaults 0 0
    none /dev/shm tmpfs defaults 0 0
    /dev/hda2 swap swap defaults 0 0
    /dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0
    /dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0

    Any new ideas??

    DA

  5. #5
    Linux Engineer
    Join Date
    Dec 2002
    Location
    New Zealand
    Posts
    766
    my fstab doesnt have user entires in it, but it has umask=0 which i _think_ means all i/o is done as user 0 (root)

  6. #6
    Linux Guru
    Join Date
    Oct 2001
    Location
    Täby, Sweden
    Posts
    7,578
    In fact, umask=0 means that all modes are set to 0777 (Since 0777 == (0777 & ~0) - the umask specifies what permission bits to "remove", so to speak. It defaults to 0022, which gives a mode of 0755).

    I'd also suggest adding the umask=0 option, unless you have security issues on your system.

  7. #7
    Just Joined!
    Join Date
    Feb 2004
    Posts
    3
    I did manage to fix it. I changed my fstab to make the Fat32 partition noauto to stop it from being loaded at boot by root and the root getting all permissions. I used my user account to mount it and now I can write to it wtout any problems. My new fstab looks like

    LABEL=/ / ext3 defaults 1 1
    /dev/hda5 /Datadisk vfat noauto,user,rw 0 0
    none /dev/pts devpts gid=5,mode=620 0 0
    none /proc proc defaults 0 0
    none /dev/shm tmpfs defaults 0 0
    /dev/hda2 swap swap defaults 0 0
    /dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0
    /dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0

    Appreciate all the help

    DA

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •