LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Perimission Denied sudoers (https://www.linuxquestions.org/questions/linux-newbie-8/perimission-denied-sudoers-4175642606/)

leydijo 11-18-2018 11:28 AM

Perimission Denied sudoers
 
installed ubuntu for the first time and I wanted my user to be an administrator so I followed some step by step that I found were
nano / etc / sudoers.
in the line that says #User privilege specification
root ALL = (All: ALL) All
leydi ALL = (All: ALL) All
save changes and then throw me this message
Error reading / etc / sudoers: permission denied
if I execute visudo it shows me visudo: / etc / sudoers: Permission denied

now it does not allow me to do anything, and I can not find the solution.

Thank you

pan64 11-18-2018 01:28 PM

duplicate of https://www.linuxquestions.org/quest...rs-4175642606/

BW-userx 11-18-2018 02:59 PM

boot a live usbstick mount your drive, if it does not auto mount it, then using root in your live os edit it back to where is was, or fix it like it needs to be.

if this is you: leydi
what groups are in sudoers, wheel, or sudo, or both, either way pick one, uncomment it, add leydi to that group, done.

BW-userx 11-18-2018 03:12 PM

N/m

scasey 11-18-2018 03:30 PM

Quote:

Originally Posted by leydijo (Post 5927374)
nano / etc / sudoers.

There should be no spaces or . I'm not sure what you actually edited. You may have created a file call etc in the directory you were in when you ran the command; or you may have created a file caled sudoers.
The command to edit sudoers is
Code:

nano /etc/sudoers
but given your newbieness, you probably shouldn't do that until you know more.


All times are GMT -5. The time now is 11:19 PM.