7

I am a new elementary OS user and I just installed it on a PC.

The installation took place as normal. However, when I put the password in and it begins to login after 3 seconds the screen goes black and back to screen users.

3
  • Hello, welcome to community, did this behaviour occur just after the installation?
    – psukys
    Nov 18, 2015 at 20:58
  • Did you install anything before this happend?
    – user3
    Nov 19, 2015 at 15:09
  • I have the same Problem but everytime i writen one of These Commands i became this answer: „command sed is in /bin/sed aviable The command could not be found because usr is not part of the environment variable PATH .“ How i can fix this Problem?
    – Nicolas
    Jun 26, 2019 at 10:16

5 Answers 5

8

Press Ctrl+Alt+F3 and login into the terminal with your username and password. Your password will not show * or anything, but it is being typed.

Now run ls ~ -lah to list files in your home folder. If in the output the line

-rw-------  1 root root   53 Nov 29 10:19 .Xauthority

appears then your .Xauthority file has the wrong permissions. You need to do sudo chown $USER:$USER .Xauthority and try logging in.

If you don't see that line, do ls -ld /tmp. Check for the first 10 letters in the left: they should read exactly like so: drwxrwxrwt.

drwxrwxrwt 15 root root 4096 Nov 30 04:17 /tmp

If they don't, you need to run the command sudo chmod a+wt /tmp and check again.

If neither of these work, I'd recommend you either

  1. Run this command:

    dpkg-reconfigure lightdm
    

    to reconfigure lightdm - the login manager.

  2. Or uninstall lightdm, and reinstall it with this command:

    sudo apt-get install --reinstall lightdm

Now restart the computer with this command:

sudo shutdown -r now

and login again.


To prevent this issue in the future, don't run GUI (Graphical User Interface) programs with sudo. If you have to (for example to open the file manager) add the -H flag - so you run sudo -H command-goes-here.

2
  • 2
    Tim, can you edit this post to explain what each of these commands is intended to do? It would also be helpful to explain what the problem is, possible causes, and how to avoid those in the future. Nov 29, 2015 at 0:25
  • 2
    @DanielForé done
    – user3
    Nov 29, 2015 at 0:28
0

i had same issue... was going around in circles.. couldn't even load a usb installer to back end the HDD version..

it was a memory issue.. i logged through tty3 and cleared out my downloads and documents and hey presto.. i only wasted 3 hours of my life!

0

I'm stuck on the login form too. I just installed Elementary and this is my very first login attempt. I already checked my .Xauthority file: it is property of my personal user (not root). I also reinstalled lightdm but nothing changed. Someone has an hint for a linux noob like me? :D Thanks a lot

0

Like PierPaolo Zus, I have the same problem right now. It happened a few days ago after installing updates. I guess something in the update broke lightdm.

I have tried all the things proposed here.

What I did as a workaround is that I installed kde-full and sddm and then I use sddm as login manager and KDE as desktop environment. This is NOT a real solution. But it is a workaround that allows me to use my computer again.

I hope someone knows how to actually fix this.

0

I've managed to get past the lock screen by accessing alternative text-based shell session with Alt + Ctrl + F1/6 then switching between login managers, namely lightdm and gdm3 by invoking sudo dpkg-reconfigure then pass your current display manageras the final argument. Finally reversed the same step back again.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.