Wednesday, February 11, 2009

Ubuntu Users and Groups

I found these commands very useful when adding users and group via the command line.

If you want to add a new user to the system. This is a standard user
adduser username

Add existing user tony to ftp supplementary/secondary group with usermod command using -a option ~ i.e. add the user to the supplemental group(s). Use only with -G option
usermod -aG www-data tony

Change existing user tony primary group to www:
usermod -g www tony

Adding a group is done similarly with this command
addgroup groupname

Add user to group can also be done like this
adduser username groupname

No comments:

Post a Comment

Raspberry Pi Zero W - Wireless Configuation

create the file under "boot" folder wpa_supplicant.conf country=GB ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev u...