-
Notifications
You must be signed in to change notification settings - Fork 1
user administraton
acavataio edited this page May 16, 2017
·
2 revisions
-
Who has logged in? (via ssh and via the terminal)
who -a (--all) -
Who is currently logged in?
who -u (--users) -
Disable a user?
sudo passwd -l username (-u to enable) -
Log a user out of your machine without disabling their account
pkill -KILL -u username -
Remove a user from the system along with their home dir
deluser --remove-home username -
Stop all processes run by a user
killall -u (--user) username -
If you wanted a file to be automatically copied to the home dir of every new user you create, where would you put it?
-become root
-cd /etc/skel
-ls -la
put the file in there to copy to home directory of every new user logging in. -
If you wanted a script to execute each time a user logged in, where would you put it?
-cd /etc/skel
- vim .profile
- add
- cat (filename)