Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

No Sudo for You

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
arius88
Posts: 6
Joined: 2022-08-02 17:56
Has thanked: 4 times

No Sudo for You

#1 Post by arius88 »

I just installed the 32-bit version of Debian 11. I tried to run an upgrade and immediately discovered that apparently I, the only user of this machine, do not have sudo privileges for some reason. The specific error is "(username) is not in the sudoers file." Which is obviously going to make fixing or upgrading anything impossible.

I'm aware that this is a common problem. But all the solutions I've found so far on the internet contain a fatal catch-22: they require me to use sudo privileges to get the sudo privileges I need. Consulting the sudo manpage didn't help.

Suggestions welcome.

arochester
Emeritus
Emeritus
Posts: 2435
Joined: 2010-12-07 19:55
Has thanked: 14 times
Been thanked: 54 times

Re: No Sudo for You

#2 Post by arochester »

To become Root input: su -
(That's su (space) (hyphen))

Then
apt-get install sudo
and
usermod -a -G sudo <username>

Replace <username> with your username to which you want to grant sudo access.

Now logout & login to get sudo access to those users.

arius88
Posts: 6
Joined: 2022-08-02 17:56
Has thanked: 4 times

Re: No Sudo for You

#3 Post by arius88 »

Hey! that fixed it. Thanks so much, arochester!

Post Reply