Services and User Management

A Linux server authenticates most users through SSSD against a central LDAP directory. An administrator must list every user account the system can resolve, including directory accounts that do not appear in the local /etc/passwd file. Which command should the administrator run?

Show the answer

Correct answerC. getent passwd

getent passwd queries every source configured in nsswitch.conf, including local files, SSSD and LDAP, so it lists all resolvable accounts. Reading /etc/passwd directly is tempting but shows only local entries and misses directory users.