Etc/sudoers Syntax Error Near Line 28
Contents |
communities company blog Stack Exchange Inbox Reputation and Badges sign up log in tour help Tour Start here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with sudo: no valid sudoers sources found, quitting sudo: unable to initialize policy plugin us Ask Ubuntu Questions Tags Users Badges Unanswered Ask Question _ Ask Ubuntu is a question and
/etc/sudoers.d/50_stack_sh: Syntax Error Near Line 1
answer site for Ubuntu users and developers. Join them; it only takes a minute: Sign up Here's how it works: Anybody can ask a question Anybody /etc/sudoers is world writable can answer The best answers are voted up and rise to the top How can I fix broken sudo - sudo: parse error in /etc/sudoers near line 23? up vote 18 down vote favorite 4 I am getting this error: sudo: parse no valid sudoers sources found quitting centos error in /etc/sudoers near line 23 sudo: no valid sudoers sources found, quitting sudo: unable to initialize policy plugin I was trying to disable password authentication so I don't have to type password every time I want to install something, but I probably changed it in a not very good way. I am a newbie to Ubuntu, I got sick of Windows :) So far I've found some people suggesting booting in single user mode, but I'm afraid of messing things up more. How can I
Sudo: Parse Error In /etc/sudoers Mac
fix this error? sudo share|improve this question edited Sep 15 '13 at 17:46 Alaa Ali 15.4k95173 asked Oct 30 '12 at 11:06 Robert Fáber 91113 If you boot in single user mode and use visudo, then it won't let you save an incorrect file, so you will not be able to mess things up further. –hexafraction Oct 30 '12 at 11:18 Thank you, how do I change the file, then? And, how exactly do I boot in single user mode? –Robert Fáber Oct 30 '12 at 11:19 2 @ObsessiveSSOℲ it would be nice to convert the comment to answer and let the questioner to mark it as the best answer. For future - help - others I mean. –NikTh Oct 30 '12 at 12:14 1 possible duplicate of How to modify a invalid /etc/sudoers file? It throws out an error and not allowing me to edit again –belacqua May 22 '14 at 22:24 2 On newer Ubuntu distributions, there's a simple solution (not requiring any reboot nor recovery), described here: askubuntu.com/a/73872 –user321342 Aug 28 '14 at 11:23 | show 10 more comments 6 Answers 6 active oldest votes up vote 12 down vote Hold Shift immediately while booting so that you get the GRUB screen. Select the recovery mode. Choose to drop to a root terminal. Run mount -n -o remount,rw / and then visudo. It'll let you fix your problems with the file and save. It won't let you save a malformed file. share|improve this answer edited
Get Kubuntu Get Xubuntu Get Lubuntu Get UbuntuStudio Get Mythbuntu Get Edubuntu Get Ubuntu-GNOME Get UbuntuKylin Ubuntu Code of Conduct Ubuntu Wiki Community Wiki Other Support Launchpad Answers Ubuntu IRC Support AskUbuntu default sudoers file Official Documentation User Documentation Social Media Facebook Twitter Useful Links Distrowatch Bugs: Ubuntu PPAs: /etc/sudoers syntax error near line what now Ubuntu Web Upd8: Ubuntu OMG! Ubuntu Ubuntu Insights Planet Ubuntu Activity Page Please read before SSO login Advanced Search Forum The
Pkexec
Ubuntu Forum Community Ubuntu Official Flavours Support New to Ubuntu [SOLVED] Can't Access Sudoers File in Ubuntu, Kubuntu, Xubuntu Having an Issue With Posting ? Do you want to help us debug the posting http://askubuntu.com/questions/209558/how-can-i-fix-broken-sudo-sudo-parse-error-in-etc-sudoers-near-line-23 issues ? < is the place to report it, thanks ! Results 1 to 8 of 8 Thread: Can't Access Sudoers File in Ubuntu, Kubuntu, Xubuntu Thread Tools Show Printable Version Subscribe to this Thread… Display Linear Mode Switch to Hybrid Mode Switch to Threaded Mode August 1st, 2012 #1 gdawg View Profile View Forum Posts Private Message 5 Cups of Ubuntu Join Date May 2010 Location New Mexico, https://ubuntuforums.org/showthread.php?t=2036382 USA Beans 39 DistroUbuntu 10.04 Lucid Lynx Can't Access Sudoers File in Ubuntu, Kubuntu, Xubuntu I managed to somehow mess-up /etc/sudoers file and now I am unable to access it. I added 2 users to the file using 'sudo visudo' command and apparently messed something up. Here are the results of attempts to access file: Code: jane@gdawg-Inspiron-530s:~$ sudo visudo sudo: >>> /etc/sudoers: syntax error near line 9 <<< sudo: >>> /etc/sudoers: syntax error near line 9 <<< sudo: parse error in /etc/sudoers near line 9 sudo: no valid sudoers sources found, quitting... sudo: unable to initialise policy plug-in I recently installed Ubuntu Remix. All help is welcome. Linux gdawg-Inspiron-530s 3.2.0-27-generic-pae #43-Ubuntu SMP Fri Jul 6 15:06:05 UTC 2012 i686 i686 i386 GNU/Linux Adv Reply August 1st, 2012 #2 drs305 View Profile View Forum Posts Private Message Staff Emeritus Join Date Jan 2007 BeansHidden! DistroUbuntu Development Release Re: Can't Access Sudoers File in Ubuntu, Kubuntu, Xubuntu Take a look at psychocat's page on fixing sudo: http://www.psychocats.net/ubuntu/fixsudo GRUB2 Retired. Adv Reply August 1st, 2012 #3 NikTh View Profile View Forum Posts Private Message Visit Homepage Ubuntu Member Join Date Feb 2012 Location el_GR BeansHidden! DistroUbuntu 14.04 Trusty Tahr Re: Can't Access Sudoers File in Ubuntu, Kubun
line 28(rpi) Post a reply 11 posts by rpi_ayu » Wed Oct 09, 2013 8:15 am when i edited my sudoers file & saved it on raspberry pi its giving me.Code: Select allsudo: parse error in /etc/sudoers near line 26
sudo: https://www.raspberrypi.org/forums/viewtopic.php?t=57750&p=434924 no valid sudoers sources found, quitting
sudo: unable to initialize policy plugin on raspberry pi
i am trying to avoid sudo permissions for a bash which is trying to access a root file i also tried pkexec as like general linux solution but its givingCode: Select allpi@raspberrypi ~ $ pkexec vim.tiny /etc/sudoers
-bash: pkexec: command not found is there any solution for this Last edited by rpi_ayu on Wed Oct 09, 2013 8:49 am, edited 1 syntax error time in total. Posts: 30Joined: Tue Sep 24, 2013 10:55 amLocation: Bhopal by FinnAnder » Wed Oct 09, 2013 8:20 am Please could you post the content of your sudoers file?As for your pkexec error, that is because it hasn't been installed (or not properly).I don't know where you got this pkexec from, but if it's on the repositories, you can install it with:sudo apt-get install pkexecHope this helps and I'll have a look at your sudoers file too. syntax error near --finnian@fxapi.co.ukfxapi.co.uk Posts: 13Joined: Sun Jul 21, 2013 4:50 pm by RaTTuS » Wed Oct 09, 2013 8:42 am sudoedit /etc/sudoers How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.htmlWARNING - some parts of this post may be erroneous YMMV1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX Posts: 8477Joined: Tue Nov 29, 2011 11:12 amLocation: North West UK by rpi_ayu » Wed Oct 09, 2013 8:51 am Code: Select allsudo: parse error in /etc/sudoers near line 26
sudo: no valid sudoers sources found, quitting
sudo: unable to initialize policy plugin on raspberry pi
still same @Rattus in all the sudo or root operations showing this Posts: 30Joined: Tue Sep 24, 2013 10:55 amLocation: Bhopal by RaTTuS » Wed Oct 09, 2013 10:00 am ok - you have damaged the sudouser file...can you su -i.e. have you a password for root if not ... then either boot to single user modeor put the sd card into a linux box and edit the file directly How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.htmlWARNING - some parts of this post may be erroneous YMMV1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX Posts: 8477Joined: Tue Nov 29, 2011 11:12 amLocation: North West UK by rpi_ayu » Wed Oct 09, 2013 10:26 am ya i don't have any password for root .......but i am trying from single user mode but its directly start booting i am continuous pressing e but its directly came onto tty (i have disabled the boot from desktop) why this is