What command adds the new user tux and creates the user's home directory with default configuration files?

Prepare for the LPI Linux Essentials 010-160 Test. Study with flashcards and multiple choice questions, each question offers hints and explanations. Get ready to ace your exam!

The command that effectively adds a new user named 'tux' and creates the user's home directory with default configuration files is the one that utilizes the useradd command with the -m option.

When the useradd command is used with the -m flag, it not only creates the user account but also automatically creates a home directory for that user, typically located at /home/tux. This directory will be populated with default configuration files (like hidden files that usually start with a dot) which are critical for user settings and preferences. These files provide a starting point for the user environment, including configuration for local applications and settings specific to the user's profile.

This feature is particularly useful in ensuring that a new user has a ready-to-use environment upon creation, eliminating the need for manual setup for basic functionality.

The other options do not fulfill the requirement as completely. For instance, while 'adduser tux' is often a valid command in some distributions, its behavior may vary and it is not universally available on all Linux systems as part of the core tools. The command 'createuser tux' is not a standard command in Linux, and thus it does not meet the criteria for adding a user. Finally, '

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy