For the past few hours I've been trying to do this 'simple assignment' for school but I can't get myself past the error: Authentication Token Manipulation Error.
What I'm supposed to do is create a script with the following
1) Create Users with standardpassword Welcome123
2) Create Groups with Groupfolder
3) Users from the same group should be able to view/edit BUT not delete non-owned/created files.
4) One group (BOSS) has access to all the (group/users)-files.
All this should be done within a 'sh-script'.
SCRIPT:
Code: Select all
#Create groups
groupadd -g 750 -f Boss
groupadd -g 751 -f Sales
#Create Groupfolders
mkdir /home/Boss
mkdir /home/Sales
#Create Users
newusers users.txt
#Password expiration
chage -d 0 -m 0 -M 90 USER1
chage -d 0 -m 0 -M 90 USER2
#Set owners of folders
chown -R :Directie /home/Boss
chown -R :Verkoop /home/Sales
#Set grouprights
chmod 760 /home/Boss -R
chmod 760 /home/Sales -R
USERS.txt:
Code: Select all
USER1:Welcome123:1001:750:Samy Dos Santos Khalil:/home/Boss/USER1:/bin/bash
USER2:Welcome123:1002:750:Dominique Miedema:/home/Sales/USER2:/bin/bash
Whenever I try to login with another account it gives me the 'enter new password' message and when I do it gives me the error: Authentication Token Manipulation Error.
What can I do to fix this problem? This is a newly installed Centos 6.5 machine and the only changes were installing updates.