useradd
The command that creates a user account.
In more detail
Options set the user ID (-u), primary group (-g), supplementary groups (-G), comment (-c), shell (-s) and home directory (-d, -m). -r creates a system account for a service.
Example
useradd -u 2001 -G devs -c "Mira Okafor" miraRelated terms
- usermod — The command that changes an existing user account.
- UID and GID — The numbers Linux uses to identify a user (UID) and a group (GID); root is UID 0.
- /etc/passwd — The world-readable file that lists local accounts, one per line: name, UID, GID, description, home directory and login shell, separated by colons.
Taught in
- Logins, su, sudo And SSH Between Hosts — Red Hat Certified System Administrator (EX200) Exam Prep
- Drill: People, Packages And Time — Red Hat Certified System Administrator (EX200) Exam Prep
- Mock Exam, Part 1: Eighteen Tasks, One Reboot — Red Hat Certified System Administrator (EX200) Exam Prep
- The App In /bin That Vanished: The FHS, Distributions And Licences — CompTIA Linux+ (XK0-006) Exam Prep
- Starters, Leavers And A Service Account: Accounts On Two Families — CompTIA Linux+ (XK0-006) Exam Prep
- Three Audit Findings And A Phone: Password Policy, Lockouts And MFA — CompTIA Linux+ (XK0-006) Exam Prep
- Graded On A Machine You Never Touched — RHCE in Ansible (EX294): Automate Red Hat Systems