Didn't have to specify a login name during installation, now it asks me for one?

7,694

You should be able to login as root with the password you set up. However, it is quite common not to allow root to log in graphically so this might be what is stopping you.

Use CtrlAltF2 at the login screen to drop to a tty and log in there. Does that work?

If that allows you to log in, create a normal user with adduser and then hit CtrlF8 (it might be F7) to go back to the login screen and try to log in with that user.


If this still does not work, you can boot into a live session and create a user from there using chroot. The basic procedure is:

  1. Boot into a Debian (or whatever) live session.

  2. Mount the / partition of your installed system in a temporary location (I am using dev/sda here, change that with the right device):

    sudo mkdir foo
    sudo mount /dev/sda1 foo/
    
  3. chroot into the mounted system, this will create a 'fake' environment that thinks it is your installed system.

    sudo chroot foo
    
  4. At this point, you should be able to create a new user

    sudo adduser username
    
  5. Reboot into the installed system and try logging in with the user you just created.

Share:
7,694

Related videos on Youtube

Hussein
Author by

Hussein

Master in Physics (2016), University of Antwerp PhD Candidate (2016-2021), imec-Visionlab, Dept. of Physics, University of Antwerp

Updated on September 18, 2022

Comments

  • Hussein
    Hussein over 1 year

    So I only created a root account during the installation process (which comes down to me only providing a root password, no name or ID or anything).

    During my first boot it sends me to a black screen (tty1) where it asks me for a login:

    (computer name) login:

    which I clearly never specified. Using 'root' and my corresponding password doesn't work. Neither does leaving "login" blank. Is this possible? Or is it some stupid mistake like an actual wrong password or a keyboard layout differing? (please consider the latter as a final explanation, I'm pretty sure that my password is correct, as I tried both possible regional layouts (azerty & qwerty, caps and non-caps)).

    Thanks in advance

  • Hussein
    Hussein over 10 years
    It immediately sends me to a tty after grub, no graphical interface whatsoever. As I said, I tried root with the only password I had to give up during the installation procedure, it just says incorrect login. What if I actually might have had a typo in my password? Is there a way to fix this or do I need to reinstall? I'm still fairly convinced that I know my password and that I didn't type it wrongly twice...
  • terdon
    terdon over 10 years
    @PatronBernard sorry, I missed the mention of "black screen". root should work there. However, your keyboard will probably be in qwerty mode, make sure you type the right password by first typing it into the login field so you can see it (I know you said you tested all combinations, its just easier if you can see what you're typing). If that still does not work, you can fix this from the live session, see updated answer.
  • Hussein
    Hussein over 10 years
    I think it came down to a typo during the installation process. I used init=/bin/bash in kernel mode to reset it. Got logged in as root, now to actually add a user I guess. But eh, why is there no GUI?
  • peterph
    peterph over 10 years
    @PatronBernard no X11 installed, wrong default runlevel, missing video driver... reasons can be plentiful.