linux - How to allow to create a directory in home folder another user -
i have 2 users:
adduser user1 adduser user2
i need allow creating folders in user2 home directory user1
user2@ubuntu: mkdir /home/user1/tmp
how can that? bacause error message:
mkdir "/home/user1/tmp" failed: permission denied
this 1 of primary purposes of group permissions in *nix. create group , make sure both users members of group, home directories have group set group-owner, , permissions on home directories include group-write. along these lines:
groupadd somegroupname usermod -a somegroupname user1 usermod -a somegroupname user2 chgrp somegroupname ~user1/. ~user2/. chmod g+rwx ~user1/. ~user2/.
Comments
Post a Comment