Users Management

Utilities

adduser, addgroup – add a user or group to the system

--systemCreate a system user or group.
--shell SHELLUse SHELL as the user’s login shell, rather than the default specified by the configuration file.
--no-create-homeDo not create the home directory, even if it doesn’t exist.
adduser --system --no-create-home proxmoxbackup
adduser --no-create-home --shell /usr/sbin/nologin proxmoxbackup

deluser, delgroup – remove a user or group from the system

--systemOnly delete if user/group is a system user/group.
--remove-homeRemove the home directory of the user and its mailspool.
--remove-all-filesRemove all files from the system owned by this user.
deluser --system --remove-home proxmoxbackup

usermod – modify a user account

-a, --appendAdd the user to the supplementary group(s). Use only with the -G option.
-G, --groups GROUP1[,GROUP2,...[,GROUPN]]]A list of supplementary groups which the user is also a member of. Each group is separated from the next by a comma, with no intervening whitespace.

Add current user to the nut group (works after logoff):

usermod -aG nut `whoami`

Random

useradd,adduser