-   Linux - Newbie (
-   -   Logged in as "root"/Fedora 8 but get "Operation not permitted" when using "chmod etc (

gosunlee 02-09-2008 12:14 AM

Logged in as "root"/Fedora 8 but get "Operation not permitted" when using "chmod etc
Hi Folks
I have been using Linux (mostly Red Hat/Fedora) for many years and have found its requirements for manipulation to achieve same as Wingows, the main reason most "non-techs" won't use it.

Recently installed Fedora 8 on SATA drive with other Fat32 partitions on it. As usual, getting Fedora to mount the partitions was a nightmare. Eventually rewrote Fstab and can now access drives but still have major problem.

When I log in as root and try to use chmod, chgrp etc I get "operation not permitted". Why??. I am root. Fstab below. Any suggestions

/dev/VolGroup00/LogVol00 / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
tmpfs /dev/shm tmpfs defaults 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
sysfs /sys sysfs defaults 0 0
proc /proc proc defaults 0 0
/dev/VolGroup00/LogVol01 swap swap defaults 0 0
/dev/sdb6 /mnt/DAD vfat rw,users,umask=0003,gid=dad 0 0
/dev/sdb9 /mnt/DATA vfat rw,users,umask=0003,gid=dad 0 0
/dev/sdb8 /mnt/FAMILY vfat rw,users,umask=0003,gid=dad 0 0
/dev/sdb10 /mnt/GENERAL vfat rw,users,umask=0003,gid=dad 0 0
/dev/sdb7 /mnt/MUSIC vfat rw,users,umask=0003,gid=dad 0 0
/dev/sda7 /mnt/EXTRATHREE vfat rw,users,umask=0003,gid=dad 0 0
/dev/sda6 /mnt/EXTRATWO vfat rw,users,umask=0003,gid=dad 0 0
/dev/sda5 /mnt/EXTRAONE vfat rw,users,umask=0003,gid=dad 0 0

Junior Hacker 02-09-2008 01:51 AM

Have you tried su - root

lazlow 02-09-2008 01:57 AM

Fat partitions do not have access rights like ext 3(or most other linux FS) do.

Lepakko 02-09-2008 02:54 AM

Aye. You may want to read about FAT by e.g. Wikipedia, where it says that 1) FAT is developed by Microsoft and as such by design is not really optimal, especially in Linux, 2) fragmentates rather quickly when compared to Linux filesystems, and most importantly 3) doesn't support POSIX standard file owners and permissions. In other words, there are no permissions, which is why you can't change them. Unfortunately you get the standard error message, when a better error would've been "There are no permissions to change."

You can still use FAT if you want to share files between Windows and Linux though, but if you'd rather change it to get the file permission support (and if you can change the FS without data loss), there are ext2/ext3 drivers for Windows available here.

gosunlee 02-09-2008 04:00 AM

Re Operation Not Permitted
Many thanks to everybody. Was unaware of problems with fat32 and Linux. Tried Ubuntu 7.04 and it didn't seem to have the same problem.

One further question. If I change gid to users will any user have access to that drive or do I have to attempt to change group name to users as well?

Lepakko 02-09-2008 05:31 AM

"gid" is a number, so you can't change that to "users", but you can change that to the gid of the group "users", like 200. You can see the list of the groups of the system in /etc/group, with the group name corresponding to each group (gid). So changing the group name doesn't make a difference, it's the group ID (the number) that does. chgrp accepts either group names or gid's. This all, of course, doesn't apply to the files on a FAT filesystem, since FAT doesn't know about groups, but you probably wanted to change the gid of the corresponding device file (like /dev/sdb7) anyway.

gosunlee 02-09-2008 07:03 AM

Re Operation Not Permitted
Hi again all (especially Lepakko)

Once again, many thanks for adding to my limited knowledge of Linux. You have all told me that fat32 does not have permissions etc yet, when I use Gnome File Browser and open the properties ->permissions for a file or directory, I get a full list of permissions for owner, group and others. Is this because of what I have entered in my fstab file??

This is a dual boot system (Fedora 8 and Windoze XP). Would it be quicker and simpler (and better) if I reformatted the partitions in question to ext3? What would be the implications with windows XP?

Lepakko 02-10-2008 05:56 AM

Gnome File Browser shows the permissions as they are (allow everything for everyone), but you can't change them. It's the same if you do 'ls -l' to FAT files; you see the rwxrwxrwx, since there are no permissions (or more exactly there are no limits). Having no support for permissions means basically you can't restrict the rights, everything is allowed instead.

It would make using your FAT partitions simpler and faster in Fedora if you reformatted them in Ext3, but you'd lose all your data during the process. There is an Ext2/3-driver for Windows, so that you would still be able to access your files of an Ext3-filesystem from Windows using that driver (found at ).

All times are GMT -5. The time now is 02:44 AM.