Edit /etc/sudoers lead fail

ileven

New Member
Joined
Jan 4, 2024
Messages
1
Reaction score
0
Credits
18
Does anyone can help me ?
I edit /etc/sudoers file deleted
ALL=(ALL) NOPASSWD: /Desktop/visits/
chenshinan ALL=(ALL) NOPASSWD: /usr/local/bin/docker
chenshinan ALL=(ALL) NOPASSWD: /usr/local/bin/docker
chenshinan ALL=(ALL) NOPASSWD: /usr/local/bin/docker
then I could not use sudo or su -

#includedir /private/etc/sudoers.d
ALL=(ALL) NOPASSWD: /Desktop/visits/
chenshinan ALL=(ALL) NOPASSWD: /usr/local/bin/docker
chenshinan ALL=(ALL) NOPASSWD: /usr/local/bin/docker
chenshinan ALL=(ALL) NOPASSWD: /usr/local/bin/docker
chenxinande-MacBook-Pro-2:visits chenshinan$ sudo vim /etc/sudoers
/etc/sudoers:61:5: syntax error
ALL=(ALL) NOPASSWD: /Desktop/visits/
^
chenxinande-MacBook-Pro-2:visits chenshinan$ cat docker-sudoers | sudo tee -a /etc/sudoers
sudo: /private/etc/sudoers.d is not a regular file
sudo: no valid sudoers sources found, quitting
sudo: error initializing audit plugin sudoers_audit
messageImage_1704347295584.jpg
 

Members online


Latest posts

Top