-
Notifications
You must be signed in to change notification settings - Fork 51
getusers
Ulrich Berntien edited this page Mar 26, 2019
·
1 revision
getusers - lists users in passwd with login shells
getusers
getusers lists all user in the passwd with a login shell.
A login shell is each program listed in the /etc/shells files. Users with shell nologin and false are never listed. Typical nologin and false are not in “shells”. But also if these programs are in the “shells” the user with this shells will be not listed.
getusers lists the user names to stdout.
Run the function. There are no command line arguments.
$ getusers
The function reads
- the /etc/passwd file through the tool getent,
- the /etc/shells file direct.