Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Possible Duplicate:
What’s the best way of handling permissions for apache2’s user www-data in /var/www?

I am setting up my first server from scratch and as I am completely novice at this I am not sure if i am doing this right.

I have my web exposed folder at /var/www and as I need to it accessible to everyone and writable by group and owner I set its permission to 774.

Is this how things are supposed to be set up or am I doing something terribly wrong?

share|improve this question

marked as duplicate by Wesley, kce, Scott Pack, Bryan, Brent Pabst Dec 14 '12 at 13:29

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1 Answer 1

up vote 1 down vote accepted

The general rule is to give the least possible permissions/privileges for users. Folders permissions should be generally either 755 (does not provide w for group) or 775 (provide w for group).

In your case, 774 might not be enough for web server process to access the folder given that it is not the owner and is not a member in its group.

share|improve this answer
    
Got it, thank you for clarifying that. –  silkAdmin Mar 18 '12 at 16:39

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