Linux Tutorials - Herong's Tutorial Examples
∟Users and Groups
This chapter provides introductions and tutorial on user and group management. Topics include commands to add and remove groups; commands to associate users with primary and supplementary groups; commands to file group ownership and group access permissions; commands to add and delete users; run 'sudo' command to gain 'root' permision.
Manage User Groups
Group Access Permissions on Files
"sudo" Command and Privilege
"adduser/usermod/userdel" - Commands to Manage Users
System Users and Groups
Add Users and Groups Manually
Takeaways:
- Use "groupadd" command to add a new explicitly.
- Use "usermod -g" command to change user's primary group.
- Use "gpasswd -a" command to assign supplementary group memership to a user.
- Use "getent group" command to view supplementary group members of a given group.
- Use "id" command to view primary group and supplementary groups of a given user.
- Use "chgrp" command to change group ownership of a given file.
- Use "chmod g=" command to change group access permissions of a given file.
- Use "wheel" or "sudo" group to grant "sudo" privilege.
- Use "sudo" command gain "root" permission for a given sub-command.
- Use "adduser" command to add a new user.
- Use "passwd" command to reset a user's password.
- Use "userdel" command to delete a user's login access and home directory.
- Read "/etc/passwd" file to see user information.
- Read "/etc/shadow" file to see user's password information.
Table of Contents
About This Book
Introduction to Linux Systems
Cockpit - Web Portal for Administrator
Process Management
Memory Management
Files and Directories
►Users and Groups
File Systems
Block Devices and Partitions
LVM (Logical Volume Manager)
Installing CentOS
SELinux - Security-Enhanced Linux
Network Connection on CentOS
Internet Networking Tools
SSH Protocol and ssh/scp Commands
Software Package Manager on CentOS - DNF and YUM
vsftpd - Very Secure FTP Daemon
LDAP (Lightweight Directory Access Protocol)
Administrative Tasks
References
Full Version in PDF/EPUB