A
A
apaicer2019-03-12 13:30:13
linux
apaicer, 2019-03-12 13:30:13

How to properly set permissions in linux?

Created users on the vps server.
1) useradd -m -d /home/mem -s /bin/false -G user,test mem
2) useradd -m -d /home/mem2 -s /bin/bash -G user,admin mem2
I wish I could using the mem2 user to open and edit a file in the /home/mem/tets directory, and mem and the rest could only read. Everything was created under root. rights to directories drwx ------- to tets rw-r-- -r--.
I do chmod 744 mem. but when I log in, both mem2 and mem are denied access.
What's wrong?
I change chmod 700 mem as root. mem has access.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
C
crazy-beard, 2019-03-21
@crazy-beard

And who is the owner of the tets folder?
Logically, it is necessary from under the root
. If it does not help, you need the output of ls -al from the folders /home, /home/mem and /home/mem/tets

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question