Which command is used to create a new user in a Linux system?

Prepare for the LPI 101-500 Certification Exam. Utilize flashcards, navigate multiple choice questions, and benefit from hints and explanations. Begin your Linux certification journey today!

The command used to create a new user in a Linux system is useradd. This command is a standard part of most Linux distributions and is typically used by system administrators to add a new user to the system. When invoked, useradd creates a new entry in the system's user database and may also create a home directory for the user, set up initial configuration files, and more, depending on the options provided.

The useradd command offers several options that allow for fine-tuning the user creation process, such as specifying the user's home directory, user ID (UID), group ID (GID), and shell. It is important to note that while adduser is also a command found on many systems, it is typically a more user-friendly frontend to useradd and may include prompts that guide the administrator through the user creation process. However, useradd is the fundamental command used on the underlying system level.

Other mentioned options like newuser and createuser are not standard commands in Linux for creating users, which is why they are not considered valid answers. Understanding the use of useradd is essential for managing user accounts efficiently in a Linux environment.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy