Article 5QA90 Managed to Lock out my account from root

Managed to Lock out my account from root

by
jasric
from LinuxQuestions.org on (#5QA90)
Hi

I recently installed Linux Mint 20.2 on my system. All was going well and I setup a samba share and added my account into a group that I use to access the samba share. Later on I restarted my Linux Mint system and now I seem to be removed from the root/sudoers group.

I don't have any other accounts with root access on the system and when I try and run sudo usermod -aG sudo <my username> I get the following error: Sorry, user <USERNAME> is not allowed to execute '/usr/sbin/usermod -aG sudo <USERNAME>' as root on linuxmint.

Also when I try and see if their are any lock files to delete I get the same sort of error.

When I try to elevate as root I get the same error. even if I run sudo -i same error.

How do I get my access back, and myself added back to sudoers group please? I really don't want to re-install my system.

Thanks

jasriclatest?d=yIl2AUoC8zA latest?i=h8dDgjoM6g4:q-r5h77rPUI:F7zBnMy latest?i=h8dDgjoM6g4:q-r5h77rPUI:V_sGLiP latest?d=qj6IDK7rITs latest?i=h8dDgjoM6g4:q-r5h77rPUI:gIN9vFwh8dDgjoM6g4
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments