If you really need to rescue the contents of the current card, flash a new card and boot the Pi from it. If you haven't done very much other customizing, just re-flash the microSD card and start over. By default, user "pi" can issue sudo commands with no password that's the way Raspbian is released. You didn't do anything wrong during setup. Is there any way around this problem or have I effectively ruined the OS? Likewise, any other use of sudo triggers the same. Sudo: no valid sudoer sources found, quitting Sudo: parse error in /etc/sudoers.d/010_pi-nopasswd near line 1 Any attempt to do so triggers the following: > /etc/sudoers.d/010_pi-nopasswd: syntax error near line 1 <<< Whether I am logged on as admin or pi I cannot use sudo for anything.(I did not create a root password before doing all this, so I can't use su either.) This means I also cannot go back and edit that file. I changed it - and here is the foolish part, working faster than I was thinking - to this: pi ALL=(ALL) NOPASSWD: The file contained just one line: pi ALL=(ALL) NOPASSWD: ALL Unclear on precisely what I was supposed to do next, I opened up 010_pi-nopasswd to edit it. Then I did the following as recommended: $ sudo deluser pi sudo I then checked the user's privileges as advised, and it worked great. Then I did the following: $ sudo adduser admin sudo ![]() How to change user pi sudo permissions how to add other accounts with different permissions?Īs that person recommended, I first added an admin user: $ sudo adduser admin I tried to change this, following some advice I found here: I'm not sure if I did something wrong while setting it up, but after getting it running I noticed that sudo commands required no passwords.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |