nerdexam
LPI

303-300 · Question #87

Which of the following commands disables the automatic password expiry for the user usera?

The correct answer is C. chage --maxdays -1 usera. chage --maxdays -1 usera disables password expiry because -1 is the special sentinel value that tells the system "no maximum age limit" - the password never expires. A is wrong because --maxdays expects a numeric argument, not the string none. B sets expiry to 99 days, which is…

Access Control

Question

Which of the following commands disables the automatic password expiry for the user usera?

Options

  • Achage --maxdays none usera
  • Bchage --maxdays 99 usera
  • Cchage --maxdays -1 usera
  • Dchage --lastday none usera
  • Echage --lastday 0 usera

How the community answered

(38 responses)
  • B
    3% (1)
  • C
    89% (34)
  • D
    5% (2)
  • E
    3% (1)

Explanation

chage --maxdays -1 usera disables password expiry because -1 is the special sentinel value that tells the system "no maximum age limit" - the password never expires. A is wrong because --maxdays expects a numeric argument, not the string none. B sets expiry to 99 days, which is a valid but non-infinite limit. D and E use --lastday, which sets the last password change date (or a forced expiry date), not the maximum age interval - --lastday 0 actually forces immediate expiry on next login.

Memory tip: Think of -1 as "minus infinity" - it removes the upper bound entirely. Whenever a Linux tool needs "no limit," -1 is almost always the answer.

Topics

#password expiry#chage command#user account security#Linux administration

Community Discussion

No community discussion yet for this question.

Full 303-300 Practice