V
V
Vladimir Krauz2016-08-25 14:03:08
linux
Vladimir Krauz, 2016-08-25 14:03:08

CentOS How to assign rights to www root folder?

Good afternoon.
Means:
I have x, y (users) and there is a dev group. There is a folder in the www root (created it via root) and in the www folder there are two more folders xxx, yyy.
The dev group must have full rights to the www folder, including rights to xxx and yyy. User x must have access to xxx and user y must have access to yyy.
Such is my task. I created users, I created a group, but I don’t know how to assign rights.
I tried this:
chmod dev+rw www/
chmod dev+rw -R www/
chmod -R dev+rwx www/
And everywhere the error is "chmod: invalid mode".
How to be?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
Dmitry, 2016-08-26
@MelancholicTheDie

chmod -R 775 and further by analogy.

S
Sergey Novikov, 2016-08-25
@BOOMER_74

Нельзя писать сразу rw или rwx и нет никаких dev, нужно так u+w,g+w. Вам нужно установить владельцем папки xxx пользователя x, yyy - y, обоим папкам задать группу dev и задать права 775 (chmod 755 папка/), т.е. владелец и группа - полные права, остальные чтение и выполнение (770 если нужно только владелец и группа).

C
CityCat4, 2016-08-25
@CityCat4

If you need to assign more than one owner or group to a folder - man setfacl/getfacl

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question