[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: File ownership problem using removeable media

On Sat, Dec 29, 2018 at 12:13:23AM +1100, David wrote:
> The command
> awk -F: '{print $1}' /etc/passwd
> will display all the known users on your machine.

A better (more general) one would be:  getent passwd | awk -F: '{print $1}'

/etc/passwd will be complete for many systems, but not for all systems,
because some machines are part of a network that uses NIS or LDAP or
similar remote authentication sources.

Reply to: