LX0-104 · Question #240
The files in the /etc/skel directory are used by the:
The correct answer is C. useradd command. The files located within the /etc/skel directory are used by the useradd command to populate a new user's home directory with default configuration files and directories upon account creation.
Question
Options
- Apwconv command
- Bpwunconv command
- Cuseradd command
- Dpasswd command
How the community answered
(32 responses)- A3% (1)
- B3% (1)
- C94% (30)
Why each option
The files located within the `/etc/skel` directory are used by the `useradd` command to populate a new user's home directory with default configuration files and directories upon account creation.
The `pwconv` command creates shadow password and group files from `/etc/passwd` and `/etc/group`.
The `pwunconv` command reverses `pwconv`, merging shadow password and group files back into their non-shadow counterparts.
The `useradd` command, when creating a new user account, copies the contents of the `/etc/skel` directory into the newly created user's home directory, providing them with initial configuration files such as shell dotfiles.
The `passwd` command is used to change a user's password, not to manage initial home directory contents.
Concept tested: Linux user management (useradd and /etc/skel)
Source: https://man7.org/linux/man-pages/man8/useradd.8.html
Topics
Community Discussion
No community discussion yet for this question.