Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

what is the exact analog of the following two commands in linux

# chmod -R +a "www-data allow read,delete,write,append,file_inherit,directory_inherit" /path/to/moodledata

$ sudo chmod -R +a "whoami allow read,delete,write,append,file_inherit,directory_inherit" /path/to/moodledata

When I run these two commands I got

chmod: invalid mode: `+a'

Here is the link where these two commands are written. http://docs.moodle.org/25/en/Installing_Moodle
Go to the section "Create the (moodledata) data directory" on that document. are those commands valid in Linux/Ubuntu? My inverstigation says than +a mode for chmod is available for Mac OS. So I want to ask from experts whether linux/ubuntu have analogs of these two commands?

share|improve this question
You do never want to chmod 777 your moodledate folder, won't you? –  ansi_lumen Sep 11 '13 at 8:49

1 Answer 1

The chmod syntax allows to combine several attributes. For example

  chmod -R +w,+x,+r /path/that/is/not/your/moodledata

would be the equivalent of what you tried to achieve. It is always better, to combine this with a user option. The -R means that the changes are going to be done recursively.

  chmod -R g+w,u+w,o-w /path/that/is/not/your/moodledata

g=group, u=user, o=others. The attributes are r ead, w rite and e x ecute. By the way, man chmod can be your friend.

share|improve this answer
thanks for the answer. i had read the man. I changed my question the way that you can understand my question. –  Unhandled Exception Sep 11 '13 at 11:25

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.