Posted in linux
2:23 am, May 19, 2022

add a user and add the user to sudo group

basic adding of a user in linux and then adding the user to the sudo group to allow it to run super user commands like apt update or other potentially system breaking commands.

Note: replace "username" with your new user account name

with your main root account you can run

adduser username

or if you already have a su added user you can run

sudo adduser username

then to add the user to the sudo group run

usermod -aG sudo username

if this does not work you can try the same command but with sudo, if you are already logged in as root then you should not need to run sudo.

sudo usermod -aG sudo username

then to login to the new account type

su username

or you can logout and then log back into the server

View Statistics
This Week
This Month
This Year

No Items Found.

Add Comment
Type in a Nick Name here
Search Code
Search Code by entering your search text above.

This is my test area for webdev. I keep a collection of code here, mostly for my reference. Also if i find a good link, i usually add it here and then forget about it. more...

You could also follow me on twitter or not... does anyone even use twitter anymore?

If you found something useful or like my work, you can buy me a coffee here. Mmm Coffee. ☕


Subscribe to weekly update emails.
Random Quote
There is a qualitative and quantitative difference between a day that begins with a little exercise, a book, meditation, a good meal, a thoughtful walk, and the start of a day that begins with a smartphone in bed.
Random CSS Property


The speak-as descriptor specifies how a counter symbol constructed with a given @counter-style will be represented in the spoken form. For example, an author can specify a counter symbol to be either spoken as its numerical value or just represented with an audio cue.
speak-as (@counter-style) css reference