Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The files in the folder "/usr/share/nginx/html" belongs to the user "nginx" (or root ?), the primary user "2x2p1p" can't modify these files, then the best thing to do is:

1 - Change the user and the group of the folder "/usr/share/nginx/html" (chown -R 2x2p1p:2x2p1p /usr/share/nginx/html)

2 - Add the user "2x2p1p" to the group "nginx" (usermod -a -G nginx 2x2p1p; chmod -R 664 /usr/share/nginx/html)

So, what shall I do ?


share|improve this question

Of these two options, the first is preferable. By adding your user to the nginx group you may inadvertently give them access to other files critical to the proper running of nginx. If you simply modify the permissions on /usr/share/nginx/html, you know exactly what you're exposing.

share|improve this answer

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.