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. Get your own self-hosted blog with a Free Domain at ($3.95/month).
  4. Become a Supporter - Make a contribution via PayPal
  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

Aaron Kili is a Linux and F.O.S.S enthusiast, an upcoming Linux SysAdmin, web developer, and currently a content creator for TecMint who loves working with computers and strongly believes in sharing knowledge.

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...

11 Responses

  1. Bilal A.Awan says:

    It worked :)
    Thank You :)

  2. Srinivas says:

    Thank you so much! This helped a lot

  3. Chaitanya says:

    Thanks a ton!!! Had a very tough doing this. This helped

  4. 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.

  5. V says:

    Sorry I want to said passwd instead of pwd

  6. 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 *