Courseiva
Administrative Tasks →hardMultiple Choice

LPIC-1 Administrative Tasks Practice Question

After creating a new user with 'useradd john', the user 'john' cannot log in. What is the most likely cause?

⚠ Common exam trap

Watch out — candidates often assume `useradd` fully provisions an account, overlooking that password assignment is a separate mandatory step, and they may confuse login failure with missing home directory or shell issues.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

No password has been set for the user

The `useradd` command creates a new user account but does not set a password. Without a password, the system's authentication mechanism (typically PAM) will deny login attempts, as there is no valid password hash in `/etc/shadow`. The user must have a password assigned via `passwd john` before they can authenticate.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    The home directory does not exist

    Why it's wrong here

    useradd without -m does not create the home directory, but login still succeeds with a warning and a default shell prompt. Missing home directories are common on minimal systems, making this a plausible but non-blocking cause.

  • ✓

    No password has been set for the user

    Why this is correct

    useradd creates the account with a locked password field, so authentication fails until one is assigned. Running passwd john sets credentials, satisfying the login requirement; without it the account remains unusable regardless of shell or home directory.

  • ✗

    The user's shell is not set

    Why it's wrong here

    useradd assigns the default shell from /etc/default/useradd, so the shell is set unless explicitly overridden. A missing or invalid shell entry in /etc/passwd would block login, but this is not the default outcome of useradd.

  • ✗

    The user is not in the sudoers file

    Why it's wrong here

    Membership in the sudoers file governs privilege escalation via `sudo`, not authentication itself, so its absence cannot block a login. It is tempting because sudoers controls administrative access, and it would be the right answer if john could authenticate but was denied root commands.

About these practice questions

Courseiva writes every LPIC-1 question from scratch — 402 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This LPIC-1 practice question is part of Courseiva's free LPI certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the LPIC-1 exam.