sudo chown : operation not permited
Hi :)
I'm a new linux user. I have a problem when trying to chown or chgrp the files on my Ubuntu 6.10. see this Code:
ahmed@shreef:/media/hda2$ su - root Code:
root@shreef:/media/hda2# ls -l this permissions problem is driving me crazy, I'm trying to compile php and mysql from source, but I always get some errors related to this permissions problem. thank you :) |
How to change files/folders ownership
sudo chown username /location_of_files_or_folders If you want to change ownership of all containing files and folders recursively, use the -R option like this: sudo chown -R username /location_of_files_or_folders How to change files/folders group ownership sudo chgrp groupname /location_of_files_or_folders If you want to change group ownership of all containing files and folders recursively, use the -R option like this: sudo chgrp -R username /location_of_files_or_folders |
:) I tried all this commands before, but the same problem.
thanks for the Webmin advice :).I'm familiar with the CLI, but this can be helpful too. thanx :) |
Quote:
Have allowed for the fact you have a space between my & docs? |
it's the same too
Code:
root@shreef:/media/hda2# chown ahmed:ahmed "my docs" I read before about something called fsktaps and mounting the HD. I don't know if these things are related to this problem. I can read and write to/from my fat32 partitions without problems, but I can't change the permissions of the files/folders even when working as root user. what I understand is that the root user can do every thing whatever it is this thing, but in my case, the root user can't even get in his shoes without help ... lol thanx :) |
I have fixed chmod's problem. I found umask=007 for all the partitions in the fstab file. I have changed it to be umask=000 .
the main problem still exists. I can't use chown or chgrp, even if I'm logged as root. any body met this problem before? thanx |
You can't chown or chmod FAT32 or NTFS partitions. Permissions for Windows partitions are defined only by umask.
|
Aha!
yes, after trying, I found that I can only chown my EXT drives. I was afraid that I did something wrong while installing Ubuntu. thank you aysiu :) |
So how can one edit files on a vfat volume in Linux?
|
errrrrrrrrr...... i dont think you need to do anything special with vfat. Just mount the partition and you should be able to write data do it. vfat does not require any special driver etc for writing from linux.
If you are unable to write to vfat partition, check the permissions. may be you are mouting the file system as read only. change that to "rw" and you should be all set. |
let me rephrase...So how can one's user (not root) account edit files on a vfat volume in Linux? Because I tried -o rw
|
on my machine this mounts the external hardisk partition sdb2 on /mnt/Temp.
All users can access and write to this partition. /dev/sdb2 /mnt/Temp auto rw,noexec,nosuid,nodev,sync,user 0 0 Alternatively, you can replace auto with vfat (since you know that the filesystem is vfat). If this this does not work try this.. /dev/sdb2 /mnt/Temp auto umask=0000,rw,noexec,nosuid,nodev,sync,user 0 0 which is basically the same but with the umask field added. Hope this helps. |
Ok that is it! I have officially tried everything! I mounted it in a different location, change the parameters, and no matter what I do the directory won't mount rw for users, and the permissions are stuck! sigh...do I need special software?
|
oh btw thanks for your help mkhan! :)
|
For those who were wondering I fixed my problem. Vfat volumes don't store owner information so Linux automatically assigns it as root. Its not easy to switch data to a different filesystem on the same drive...I lost data in the transfer. :'(
|
All times are GMT -5. The time now is 09:50 PM. |