LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-14-2024, 08:15 AM   #1
kimhsbrn1
LQ Newbie
 
Registered: Apr 2024
Posts: 4

Rep: Reputation: 0
sudo code not working


*New Linux user here!*

I just wiped one of my laptops out yesterday and installed Linux/Ubunto. My passwords weren't working, so I did a bunch of research, and here is what I found:

I got to the grub menu and went into recovery mode. Typed:

mount -rw -o remount /
passwd <username>

I entered a password, and was very happy that I was able to use sudo commands once again.

But, I'm back at it this morning (trying to get Zoom to work) and my sudo code is not working! I entered the password that worked yesterday and I get, "Sorry, try again."

I redid the process from yesterday and changed the password to a new one. But that isn't working either.

What do I do now? I spent hours on this yesterday, so it's quite frustrating. Hoping someone will take the time to walk me through this.
 
Old 04-14-2024, 08:22 AM   #2
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,587
Blog Entries: 19

Rep: Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455
Try logging out and logging in again with the new password. Does sudo work then?
 
Old 04-14-2024, 08:37 AM   #3
kimhsbrn1
LQ Newbie
 
Registered: Apr 2024
Posts: 4

Original Poster
Rep: Reputation: 0
Thanks for responding so quickly!
Please forgive my ignorance... will you tell me exactly what you mean by logging out and in? Is that simply closing out of the terminal and opening it again, or is there something more to "logging out"?
 
Old 04-14-2024, 08:46 AM   #4
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,587
Blog Entries: 19

Rep: Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455Reputation: 4455
No, I mean logging out of the whole system. Use the exit option in your desktop menu. There should be a sub-option for logging yourself out without halting or rebooting.
 
1 members found this post helpful.
Old 04-14-2024, 08:51 AM   #5
Turbocapitalist
LQ Guru
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 7,313
Blog Entries: 3

Rep: Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723Reputation: 3723
Quote:
Originally Posted by kimhsbrn1 View Post
will you tell me exactly what you mean by logging out and in?
Logging out of the whole system (desktop environment) such that you have to re-enter your password again to get back in. The reason for that is your desktop environment session is under the old group settings and the changes to the groups won't take effect until you have a new session. That is if you changed group membership for that account in order to get "sudo access".

Perhaps it would help if you could explain the steps you have taken in attempting to restore access.
 
1 members found this post helpful.
Old 04-14-2024, 09:22 AM   #6
kimhsbrn1
LQ Newbie
 
Registered: Apr 2024
Posts: 4

Original Poster
Rep: Reputation: 0
Thank you! I logged out and back in. The code is working again. I appreciate your help!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: The Differences between Su, Sudo Su, Sudo -s and Sudo -i LXer Syndicated Linux News 0 09-15-2022 07:47 PM
[code]sudo printf "..." >> text.etc[/code] ? jamison20000e Linux - Software 1 08-07-2015 01:07 PM
LXer: The Ultimate Sudo FAQ — To Sudo Or Not To Sudo? LXer Syndicated Linux News 13 04-13-2013 01:36 AM
Can't use sudo, only account that's not root is not a sudo'ers [Ubuntu 9.10] randyriver10 Linux - Desktop 1 01-09-2010 07:56 PM
LXer: sudo, or not sudo: that is the question LXer Syndicated Linux News 0 02-07-2008 05:40 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:06 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration