bruce080 Posted September 28, 2009 Share Posted September 28, 2009 I need help removing some write-protected files. On the linux machine, I am a member of the group "www-data" and am trying to remove files from the the directory named "customer_care". The file permissions for this directory is below: sbruce@msa1:/var/www$ ls-l drwxr-xr-x 9 www-data www-data 4096 2009-09-25 11:19 customer_care My group is the owner of the directory, but yet I am running into permissions errors when trying to remove files (the file permissions are the same). Is there a problem with o=rwx and g=r-x? Do the group permissions also have to be rwx even though the group is the owner of the directory? Thanks, Steven Quote Link to comment https://forums.phpfreaks.com/topic/175819-solved-file-permissions/ Share on other sites More sharing options...
broseph Posted September 28, 2009 Share Posted September 28, 2009 Upon careful inspection, you are correct: your group permissions are the problem. Additionally, you *may* be misunderstanding whats going on with unix permissions. Is there a problem with o=rwx and g=r-x? Do the group permissions also have to be rwx even though the group is the owner of the directory? The owner (rwx) is www-data. You are a member of the group www-data (r-x). Again: The directory's OWNER, is the user www-data, the directory's GROUP is the group www-data. This does not mean if you are in the www-data group, that you are the owner. The naming here is confusing and I think thats where you are getting hung-up. Imagine if you changed the owner to 'bruce080'. This would not affect anyone's permissions in the www-data group, because www-data doesn't 'own' the directory, 'bruce080' does. The short answer is you need write permissions for group. Quote Link to comment https://forums.phpfreaks.com/topic/175819-solved-file-permissions/#findComment-926486 Share on other sites More sharing options...
bruce080 Posted September 28, 2009 Author Share Posted September 28, 2009 Ahh yes, I was under the assumption that a group could be the owner of a file. This makes more sense. Thank you. Quote Link to comment https://forums.phpfreaks.com/topic/175819-solved-file-permissions/#findComment-926498 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.