0

I got kubuntu 12.04 on my laptop, but everytime I try t update, install or something like that it does not recoginze my password, here is what the konsole says...

ernesto@neto-desktop:~$ sudo apt-get update
[sudo] password for ernesto: 
Sorry, try again.
[sudo] password for ernesto: 
Sorry, try again.
[sudo] password for ernesto: 
Sorry, try again.
sudo: 3 intentos de contraseña incorrectos
ernesto@neto-desktop:~$ 

and no advance from there, i am some kind of new for this version (12.04 precise pangolin) and i m not sure what is next, thanks in advance for the help and answers!

Thomas Ward
  • 74,764
  • The root user password may be Wrong – Babin Lonston Oct 18 '13 at 04:39
  • 2
    It is not the root password but a password of the user who has admin privileges. Read about the differences between sudo and root here: https://help.ubuntu.com/community/RootSudo – Tanel Mae Oct 18 '13 at 04:39
  • Does the password work when you log in? Or do you have automatic login activated? – MadMike Oct 18 '13 at 05:00
  • sorry for the delay, (kinda busy rehearsing and stuff...) i do have automaitc login, and befroe that i use to manage the password for make changes as root, but nos i,ve already ttried to make the changes that told me in the answer below, and still the same issue, what can i do next? maybe change to xubuntu? – Neto Diaz Oct 23 '13 at 01:14

1 Answers1

-2

How to fix “username is not in the sudoers file. This incident will be reported” Error In Ubuntu

Reboot the computer. If Ubuntu is your primary and the only operating system in your computer, press the “Shift” button when it is booting up. This should make the Grub screen show up on your monitor. On the Grub screen, press the down button to the Recovery mode and press Enter.

On the next screen, select “Check all file system (will exit read only mode)”.

When you see the message “Finished, press Enter“, press Enter.

Next, select “Drop to root shell prompt”.

You will now be at the command line. Type:

usermod -a -G root your_user_name_here

Replace the username with your own login name.

That’s it. Now type “exit” and select “Resume normal boot”. Follow the Steps below if u messup With sudoers file

Do the Steps Untill 3

sudo cp /etc/sudoers /etc/sudoers.backup

sudo vim /etc/sudoers

Check the following lines in the file

# This file MUST be edited with the 'visudo' command as root.
#
# Please consider adding local content in /etc/sudoers.d/ instead of
# directly modifying this file.
#
# See the man page for details on how to write a sudoers file.
#
Defaults        env_reset
Defaults        secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

# Host alias specification

# User alias specification

# Cmnd alias specification

# User privilege specification
root    ALL=(ALL:ALL) ALL

# Members of the admin group may gain root privileges
%admin ALL=(ALL) ALL

# Allow members of group sudo to execute any command
%sudo   ALL=(ALL:ALL) ALL

# See sudoers(5) for more information on "#include" directives:

#includedir /etc/sudoers.d

Next save the file using

 wq!

Next Change the permission to the sudoers file

chmod 440 /etc/sudoers

Then Add your Username to the Sudo group

usermod -a -G root your_user_name_here

Exit the Shell and resume normal boot are restart ...

This Will Fix Your Issue , i'm Following this and Its Found from google , While i faced the same issue ..

  • updated with vim – Babin Lonston Oct 18 '13 at 04:31
  • Why do you make him check his filesystem? You should add the reason in the answer. After dropping to root, you forget to remount the drive as rw. You should stick to nano, your target audience won't know how to use vim. – MadMike Oct 18 '13 at 04:43
  • You should edit the sudoers-file with visudo. You need to add the user to admin and sudoers not to root. Giving the links from where you took the guides would be nice. – MadMike Oct 18 '13 at 05:05
  • thanks for the answers, but it seems that as been solved, in any case i leave this open, just in case, i'll reboot and aile the answer that i found was in this question: http://askubuntu.com/questions/128213/admin-password-authenticates-to-log-in-but-not-to-install-apps-or-change-user-a?rq=1 with the answer of naskoos and just to add something: – Neto Diaz Oct 23 '13 at 02:23
  • well, reboot and updated has been done, all systems ok, (including new password) by the way, i added the line "ernesto ALL (ALL:ALL)" ALL (ernesto is my username) just below "Allow members of group sudo to execute any command %sudo ALL=(ALL:ALL) ALL" by using sudo nano /etc/sudoers and the other info on the link before this one, so, so far seems to be ok! thanks to this forum that let us learn and grow everytime! – Neto Diaz Oct 23 '13 at 03:23