HELP - Directory Permissions
Once I create a new user, I want him to only have access to 1 directory that I will create, I want him/her to have write and read access only.
Running Red Had Enterprise I know I add a user - useradd and create a password, problem is I don't want this user to see anything else other that the one directory I want him to copy files to. |
Do the accounts already exist?
If yes, it's trivial: Code:
for i in acc1 acc2 acc3 ... ; do mkdir $i; chown $i $i; chmod go-rwx $i; done Code:
for i in `cat list` ; do mkdir $i; chown $i $i; chmod go-rwx $i; done Cheers, Tink |
Quote:
|
Quote:
as for the new question: I'm afraid that that request isn't very feasible. You can't trivially lock users out of the entire file-system; you can stop them from seeing each others files, though, which still works in the way I described, just use their actual home directories. |
Quote:
|
Assuming that you have a list like
Code:
/home/user1 Code:
for i in `cat list` ; do chown -R $i $i; chmod -R go-rwx $i; done Cheers, Tink |
All times are GMT -5. The time now is 04:49 PM. |