Bird
0
0

Which of the following is the correct syntax to change the password for user alice as root?

easy📝 Syntax Q12 of 15
Linux CLI - Users and Groups
Which of the following is the correct syntax to change the password for user alice as root?
Apasswd -p alice
Bpasswd -u alice
Cpasswd --change alice
Dpasswd alice
Step-by-Step Solution
Solution:
  1. Step 1: Recall root usage of passwd

    Root can change any user's password by running passwd username.
  2. Step 2: Analyze options for correct syntax

    Only passwd alice uses the correct syntax. Options A, B, and C use invalid or non-existent flags.
  3. Final Answer:

    passwd alice -> Option D
  4. Quick Check:

    Root changes user password with passwd username = D [OK]
Quick Trick: Use passwd username as root to change others' passwords [OK]
Common Mistakes:
  • Adding wrong flags like -u or -p
  • Using --change which is not a valid option
  • Trying to change password without specifying username as root

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Linux CLI Quizzes