From the course: Linux CentOS 7: User and Group Management
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Create and delete users - Linux Tutorial
From the course: Linux CentOS 7: User and Group Management
Create and delete users
- [Instructor] You night remember from another video in this course, that user accounts are stored in /etc/passwd. Passwords and accounts aging are stored in /etc/shadow. And other account defaults are stored in /etc/login.defs and /etc/default/useradd. /etc/default/useradd also specifies our skeleton directory. The skeleton directory contains the files that are copied to each user's home directory automatically. We'll observe this in a moment. The process of creating users in Linux is pretty straightforward. Let's go to a terminal and type in sudo useradd with no arguments. Type in sudo space useradd and hit Enter. Now type in your password and hit Enter again. Here we can see the many options for useradd. Thanks to the stored defaults, we don't have to specify any options to create a user. Any options that we leave out, are taken from the system-wide defaults. Let's create a new user by typing in sudo useradd bob and hit Enter. We can verify that this user exists by viewing the…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.