Bird
0
0

If a user 'john' is deleted using userdel john, what happens to his home directory by default?

medium📝 Command Output Q5 of 15
Linux CLI - Users and Groups
If a user 'john' is deleted using userdel john, what happens to his home directory by default?
AThe home directory is moved to /tmp
BThe home directory is deleted automatically
CThe home directory remains intact
DThe home directory is archived
Step-by-Step Solution
Solution:
  1. Step 1: Understand userdel default behavior

    By default, 'userdel' removes the user but leaves the home directory intact.
  2. Step 2: Note options for deleting home

    To delete home, '-r' option is needed; without it, home stays.
  3. Final Answer:

    The home directory remains intact -> Option C
  4. Quick Check:

    Default userdel home behavior = C [OK]
Quick Trick: Use 'userdel -r' to remove home directory [OK]
Common Mistakes:
MISTAKES
  • Assuming home is deleted without -r
  • Thinking home is moved or archived
  • Confusing userdel with usermod

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Linux CLI Quizzes