User account management
Content |
Description
On POSIX-compatible systems, each user is identified by a string called a ‘user name’ and a non-negative integer called a ‘user ID’. Every user is a member of at least one group, and has a home directory and default shell. User accounts may provide the ability to log in to a system, or may serve some other purpose such as providing an identity for a system service.
Information about each user is recorded in the ‘user database’, which can be queried using the getent
command or the
getpwuid
and getpwnam
system calls. On most modern systems, queries to the user database are
directed through the Name Service Switch. This allows for user account information to be obtained from a combination of sources, which usually
includes the local password file, and may include remote directory services such as LDAP, NIS or Hesiod.