H12-725_V4.0 · Question #69
On a Linux host, which of the following files can be viewed to count all user names and login methods in the current system?
The correct answer is A. /etc/passwd. /etc/passwd is the correct answer because it stores one entry per user account on the system, with fields for username, UID, GID, home directory, and default shell - making it the definitive source for counting all usernames and their configured login shells (login method)…
Question
On a Linux host, which of the following files can be viewed to count all user names and login methods in the current system?
Options
- A/etc/passwd
- B/etc/profile
- C/etc/shadow
- D/etc/rc.local
How the community answered
(26 responses)- A81% (21)
- B12% (3)
- C4% (1)
- D4% (1)
Explanation
/etc/passwd is the correct answer because it stores one entry per user account on the system, with fields for username, UID, GID, home directory, and default shell - making it the definitive source for counting all usernames and their configured login shells (login method). /etc/shadow (C) stores hashed passwords and account expiry info but is not the primary source for enumerating users or login methods. /etc/profile (B) is a shell initialization script that runs at login and contains environment variable settings, not user account data. /etc/rc.local (D) is a legacy startup script for running commands at boot and has nothing to do with user accounts.
Memory tip: Think of /etc/passwd as the "guest list" - every user who can walk through the door is listed there, along with how they get in (their shell).
Topics
Community Discussion
No community discussion yet for this question.