1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

No login possible after sudo in Mint

Discussion in 'Crashed!' started by cloasters, Mar 12, 2016.

  1. cloasters

    cloasters Moderator

    Joined:
    Jul 3, 2013
    Messages:
    8,383
    Likes Received:
    82
    Trophy Points:
    48
    How embarrassing, I can't log in after sudo. Password is correct, but I are doing it wrong somehow. Good grief.
  2. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    Err...caps lock?
  3. Daerandin

    Daerandin Well-Known Member

    Joined:
    Oct 18, 2013
    Messages:
    1,130
    Likes Received:
    243
    Trophy Points:
    63
    Location:
    Northern Norway
    Home page:
    If you have ruled out caps lock as the culprit, then things certainly are more complicated. We could try to rule out issues with the login manager, and instead attempt a login from the console. So you can try to press Ctrl+Alt+F2 which should give you the console where you can type in your username and then your password.

    If you can remember what you did with sudo, that could also help understand if it was the possible cause to the issue.
  4. cloasters

    cloasters Moderator

    Joined:
    Jul 3, 2013
    Messages:
    8,383
    Likes Received:
    82
    Trophy Points:
    48
    Caps lock wasn't the problem, let me try Ctrl+Alt+F2 again. Thank you Daerandin!
  5. cloasters

    cloasters Moderator

    Joined:
    Jul 3, 2013
    Messages:
    8,383
    Likes Received:
    82
    Trophy Points:
    48
    My "shorthand" name is given on the command line, I type in my password--it isn't accepted. I'm typing in the right password and it worked a few days ago. Argh, I think I'm in trouble here. It seems to want a different password? But there isn't one ttbmk.
  6. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    George, let me understand you. You can login to the machine when it boots, but you can't su to root with your known good password in a console window?

    Please paste the output of:

    Code:
    groups cloasters
    or substitute your username for 'cloasters' of course

    It should show you something like:

    Code:
    thunderrd@Q6600:~$ groups thunderrd
    adm wheel audio cdrom video cdrw usb users portage cron wireshark games realtime samba vboxusers storage
  7. cloasters

    cloasters Moderator

    Joined:
    Jul 3, 2013
    Messages:
    8,383
    Likes Received:
    82
    Trophy Points:
    48
    Very shortly after installing Mint the machine asked for no password during boot. I didn't like it but have no idea how to make it ask for my one and only known password to be able to boot. At this point I'm afraid to find out what happens if I try to lock the screen. Thank you very much for your fast response, ThunderRd!
  8. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    Show us the above output
  9. cloasters

    cloasters Moderator

    Joined:
    Jul 3, 2013
    Messages:
    8,383
    Likes Received:
    82
    Trophy Points:
    48
    OK. I get "groups my first name-second name adm cdrom sudo dip plugdev lpadmin sambashare." Then the prompt returns as "firstname-secondname contraction of first and second name ~$"

    Thank you very much for your help, ThunderRd!
  10. Daniel~

    Daniel~ Chief BBS Administrator Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    11,172
    Likes Received:
    161
    Trophy Points:
    63
    Location:
    Greenwater WA
    Home page:
    So can you now login past sudo?
  11. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    George, open a terminal and type
    Code:
    su -
    then 'enter'. [that's a hyphen]

    Then, see if you can get a root prompt there by typing your password.

    Can you not copy/paste the contents of your terminals?

    You can redact the sensitive information if you want. It should look something like this:
    Code:
    thunderrd@Q6600:~$ su -
    Password:***************
    root@Q6600: ~#
    Also, please show me what is failing. What command are you issuing after the 'sudo' command? 'sudo' is not a standalone command. It needs to be followed by a command issued with proper syntax for that command.

    For example, you type 'sudo apt-get dist-upgrade -s' and the system asks for your password. You don't type 'sudo' and enter. That is for 'su' as I have shown you above. 'su' will show me if you can get elevated privileges in the terminal itself, without a command being issued.

    I'll check, but I also believe you have to have your user in the 'wheel' group to use elevated privs, and I don't see you there with the groups command. Let's see if you have an existing 'wheel' group. Please type
    Code:
    groups
    and show me the output?
  12. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    Hmm, looks like Debiankinder don't install the wheel group by default, so I guess that's not your problem. You shouldn't need it if sudo is working properly, anyhow. The wheel group is a vestigal UNIX thing and its presence seems to depend on the distro in use. Your output shows that you ARE in the sudo group, so that should be OK.

    So back to the other questions:

    1. What, *EXACTLY*, are you typing when you use 'sudo'? What command are you following it with?

    2. Can you raise a root prompt in a terminal by using 'su -' and typing the password?
  13. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,278
    Likes Received:
    614
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    Maybe we could show him how to create another (admin) account and use that account to change the password for his main account?
  14. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    Gotta find the problem first. He knows it worked before, and I have never seen a password mysteriously become unusable. He's apparently in the sudo group, and I expect the su command to fail because there is no wheel group. He can't create an account with admin powers unless he's root, and apparently he can't get there. I *suspect* he should try re-booting, but I'm doing some research before I tell him to try that.

    We also should take a look at /etc/sudoers and see if there is a problem there, but unfortunately 'visudo' is needed to edit that, and it MUST be run as root, and he can't get there, so again, it's a bad circle.

    Maybe there is a keyring problem of some sort.

    We also completely derailed that thread, so that is why I've moved it here.
  15. Gizmo

    Gizmo Chief Site Administrator Staff Member

    Joined:
    Dec 6, 2012
    Messages:
    2,230
    Likes Received:
    156
    Trophy Points:
    63
    Location:
    Webb City, Missouri
    Home page:
    Agreed, we need to find out exactly what he's typing and trying to sudo, first.
  16. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,278
    Likes Received:
    614
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    Good point, I forgot super user needs to password-in just to create an account.
    Is there a way to reset passwords without "sudo"?
    This is a common problem in Windows when someone forgets their password. If they don't know the Administrator password then the only way onto their computer is using a rescue flash drive where I can reset the admin password.
    Not sure how to do it in Linux.
    If this happened to me... I would re-install Linux... sadly :(
    If anything its good experience having to re-install.

    He can't even "passwd root" because it requires "sudo"
  17. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    I'm thinking a keyring problem, maybe a master pw has been set on top of the regular one.
  18. Gizmo

    Gizmo Chief Site Administrator Staff Member

    Joined:
    Dec 6, 2012
    Messages:
    2,230
    Likes Received:
    156
    Trophy Points:
    63
    Location:
    Webb City, Missouri
    Home page:
    Doesn't Mint still use the /etc/passwd and /etc/shadow files?
  19. ThunderRd

    ThunderRd Irreverent Query Chairman Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    2,756
    Likes Received:
    87
    Trophy Points:
    48
    Location:
    Northern Thailand, the Land of Smiles
    Home page:
    I think that is SOP in all Debian-type distros. Maybe one of the boys running Mint can check?

    Bedtime for me, I'll check back in the morning.
  20. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,278
    Likes Received:
    614
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    Yup, /etc/passwd is there, opened it with nano and it lists all of my accounts.

Share This Page