How to Fix “Username is not in the sudoers file. This incident will be reported” in Ubuntu

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Use our Linode referral link if you plan to buy VPS (it starts at only $10/month).
  4. Support us via PayPal donate - Make a Donation
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

Aaron Kili

Computer Science student at Makerere University. Am a Linux enthusiast and a big fan of FOSS. I have used Linux for one year and six months now. I love to share ideas and knowledge around me and in other places around the world.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide

You may also like...

5 Responses

  1. Martins Almeida says:

    Thank you for keeping to provide us, users of Ubuntu OS, with important tips on how to overcome common and daily situations we may face.

  2. V says:

    Sorry I want to said passwd instead of pwd

  3. V says:

    There is a lot more to said about this. What about if at recovery time, root have been setup with a different password from defaults? The system ask for password, there is only one way to proceed, mount / with a live CD or USB drive and mount then chroot to / and use pwd command to do what you want. Hope this help/improve.

    • Aaron Kili K says:


      In recovery mode, you will always get a passwordless root shell, and have absolute control over the system to perform required changes in the system hence the name “recovery mode”.

      Try to go through this Ubuntu documentation about lost password, it covers the same thing here but focuses on resetting a password other than fixing broken sudo in recovery mode: You will get a full root access in recovery mode, whether root password was set to something different or not on Ubuntu.

      Lastly, thanks for sharing your useful thoughts on the subject matter.

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

Join Over 300K+ Linux Users
  1. 177,942
  2. 8,310
  3. 37,548

Are you subscribed?