Kattungen95
Posts: 3
Joined: Thu Oct 20, 2016 3:00 pm

Can't get past login-screen

Thu Oct 20, 2016 3:09 pm

Hello

I wanna start off by saying that i am a beginner with Linux.
I recently got some weird problem where I can't log in from the login-screen but is fine when i login from ssh with the same username and password, what could be the problem?

This started after that I had changed my timezone with Raspi-config. I changed from EU timezone to UTC+1 ( I live in sweden ). I have had some problem before because every time i connect a keyboard it sets it to a EU keyboard layout however i typed my password in the Username section to see if it was right then copy/pasted in into the password section but still wont let me login. using the same username and password from SSH works fine. this prohibit me from finishing my school-project. I have to say i have only had problems with Linux and i am starting to tip all of my hair off :x

User avatar
lmarmisa
Posts: 1299
Joined: Thu Feb 14, 2013 2:22 am
Location: Jávea, Spain

Re: Can't get past login-screen

Thu Oct 20, 2016 8:08 pm

Does your password contain other chars than letters and numbers?.

If there is a problem related to the country of the keyboard layout, you will be unable to login (from the log-in screen) if your password includes chars that are mapped on different keys depending on the specific country selected. By contrast, the letters and numbers are assigned to the same keys on (almost) all keyboards, regardless of country code.

The access by means of ssh has an independent keyboard configuration and it is not affected by the country layout. This could explain the different behavior between ssh and login screen.

If this is your case, establish a connection to your RPi with ssh and change your password (remember, only letters and/or numbers!!!). Type this command:

Code: Select all

passwd

Kattungen95
Posts: 3
Joined: Thu Oct 20, 2016 3:00 pm

Re: Can't get past login-screen

Fri Oct 21, 2016 10:00 am

lmarmisa wrote:Does your password contain other chars than letters and numbers?.

If there is a problem related to the country of the keyboard layout, you will be unable to login (from the log-in screen) if your password includes chars that are mapped on different keys depending on the specific country selected. By contrast, the letters and numbers are assigned to the same keys on (almost) all keyboards, regardless of country code.

The access by means of ssh has an independent keyboard configuration and it is not affected by the country layout. This could explain the different behavior between ssh and login screen.

If this is your case, establish a connection to your RPi with ssh and change your password (remember, only letters and/or numbers!!!). Type this command:

Code: Select all

passwd
thanks for the reply. The thing is that i have already changed my password through the SSH terminal with the "passwd" command and restarted my Pi, it still wont let me log in. I had a hyphen in my password but i deleted the hyphen with my new password. This is really weird. I even wrote my password in the username section first to see the password without the " **** " stars.

User avatar
lmarmisa
Posts: 1299
Joined: Thu Feb 14, 2013 2:22 am
Location: Jávea, Spain

Re: Can't get past login-screen

Fri Oct 21, 2016 11:10 am

Have you tried to select the auto-login options with the utility raspi-config?

Type this command:

Code: Select all

sudo raspi-config
Then select 3 Boot options -> B1 Desktop /CLI -> B2 Console Autologin or B4 Desktop Autologin.

BTW: Have you checked if the login screen problem is common to the console and the GUI modes?.

wh7qq
Posts: 1475
Joined: Thu Oct 09, 2014 2:50 am

Re: Can't get past login-screen

Fri Oct 21, 2016 7:42 pm

Regarding your keyboard problem, unless you load from Noobs and change the keyboard selection in the panel at the bottom of the OS selection page, the keyboard will revert to gb or eu every time. If you load Raspbian directly, you don't have that option and it will change back regardless of what you do in raspi-config or the config gui. The only option that seems to work is to go into the keyboard defaults and change it there:

Code: Select all

sudo nano /etc/default/keyboard
Your login is probably still looking for the original default user. Try to log in with user "pi" and password "raspberry" and see if that works. You probably need to set up a new user account for your new username and password (but please do not use the same login and password):

Code: Select all

sudo useradd "your user name" 
followed by:

Code: Select all

sudo passwd "your user name"
and the new password for that account. To remove a user, use

Code: Select all

userdel "username" 
or

Code: Select all

userdel  -r "userrname"
if you also wish to remove the home directory for that user.

Failing that, your simplest (but dirty) course is to reformat your SD card and load a fresh copy of Noobs or Raspbian and start from scratch (incorporating the change in the /etc/default/keyboard file if you load Raspbian). Don't overlook the panel at the bottom of the OS selection page if you load from Noobs.

Hang in there with linux...you don't have much choice with a Raspberry Pi but once you get past the initial learning curve, it is much easier than W$.

User avatar
jojopi
Posts: 3326
Joined: Tue Oct 11, 2011 8:38 pm

Re: Can't get past login-screen

Fri Oct 21, 2016 10:47 pm

Kattungen95 wrote:I can't log in from the login-screen but is fine when i login from ssh with the same username and password, what could be the problem?
Do you actually see a message such as "incorrect password"?

If the screen just goes blank and then returns to the login dialog, your GUI session failed to launch. Common causes for that are the disk being full (check with "df /"), or permissions issues within the user's home directory.

Kattungen95
Posts: 3
Joined: Thu Oct 20, 2016 3:00 pm

Re: Can't get past login-screen

Mon Oct 24, 2016 10:59 am

I had to reinstall the os after all, but thanks everyone who replied

Return to “Troubleshooting”