What to do when nothing seems to fix Ubuntu 14.10 stuck after log in?
I am facing the same situation, frankly I don't have the time to go through the logs and fix it plus I am afraid I will ruin something again and I can't spare any time right now to reinstall Ubuntu and/or try any fix so I am dealing with it the following way.
What I am doing to get access to my machine after getting stuck on login page is the following:
1- After rebooting and landing on login page I go to a TTY (ctrl+alt+F1
).
2- Login as my normal user.
3- kill lightdm running processes sudo killall -u lightdm
4- remove Xauthority file rm .Xauthority
, the one under my normal user account i.e: ~myUsernameAccount/.Xauthority
.
5- make sure no lightdm instance is still running with ps aux | grep lightdm
root 2412 0.0 0.0 89496 2600 tty1 S 16:59 0:00 sudo lightdm
root 2413 0.0 0.1 351608 4100 tty1 SLl 16:59 0:00 lightdm
root 2418 0.5 1.0 312932 39132 tty7 Ssl+ 16:59 1:57 /usr/bin/X -core :0 -seat seat0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
root 2491 0.0 0.1 188932 4700 tty1 Sl 16:59 0:00 lightdm --session-child 12 19
ash 8723 0.0 0.0 15944 916 tty1 S+ 23:15 0:00 grep --color=auto lightdm
See in the previous output, lightdm is lunched as root so killall -u lightdm
won't work, so I do the following: sudo kill 2412 2413 2418 2491
, but if the system is just booted up then you will see lightdm instead of root and that command will work fine, (also notice that the last line is grep output command and is always shown so ignore it)
Now if you check ps aux | grep lightdm
again the output should be something similar to this only:
ash 8759 0.0 0.0 15940 912 tty1 S+ 23:17 0:00 grep --color=auto lightdm
6- lunch lightdm again sudo lightdm&
.
7- Switch to GUI (ctrl+alt+F7
) again.
8- Login normally, it mat get you back to F1 TTY so again go to GUI using ctrl+alt+F7
, wait for few seconds till the crash report is completed and I will be on my desktop.
P.s: using this method, you have to enter the system key everytime you do something that requires root privileges, for example: I can't edit network connections from the top panel directly, I have to call the networking from terminal using sudo
, ...etc.
Ofcourse this is not a good practice at all, but I hope it will help someone to get around the problem for a little amount of time.
Related videos on Youtube
Lucas
Updated on September 18, 2022Comments
-
Lucas over 1 year
So I run Ubuntu 14.10 on HP Pavilion g6, i5 and with Radeon HD6500. Yesterday Ubuntu crashed and since then I can't get anyfurther than the log in screen. Ubuntu simply stucks with only the background and cursor visible. It seems to be stuck in log in and there are a lot of fixes all over the internet for this. Non of them seems to help. I will explain step by step what I done so far.
Update 1 dec 2014: Followed recommendation from @ash and didn't fix the problem. Still think @ash fix will solve similar problems, but not for me. I reinstalled Ubuntu and that fixed the problem, so the problem was probably graphically. If anyone have any idea what may have happend, please answer.
- Changing dm
First I tried changing dm to gdm (also suggested in a comment here).
sudo dpkg-reconfigure gdm
That didn't work. I even tried
lxdm
, but no result there either. After I tried that I read that I might check50-ubuntu.conf
and did so. Nothing strange over there. Also triedstop
andstart
forlightdm
, no result. Then I found this and triedsudo dpkg-reconfigure gdm sudo apt-get remove lightdm* --purge sudo reboot sudo apt-get install lightdm* sudo dpkg-reconfigure lightdm
I'm was not a fan of the hole
lightdm* --purge
but tried it anyway. It didn't fix my problem, but I guessed it would remove a lot of packages that wasn't really related to the problem. What I didn't guess was that it would change the graphics this much. I could of course realized thatinstall lightdm*
would install a lot of unnecessary packages. When I rebooted the computer it said Ubuntu Studios instead of 14.10 and the log in screen looks messy. Also, the computer gets stuck in a black screen with only the cursor visible instead of as earlier. Well, stupid of me to take a bad advice (if anyone have any quick fix for this I would really appreciate it).Anyway, nothing of this fixed my problem.
- Reinstalling Unity and ubuntu-dekstop
After reconfiguring
lightdm
I tried to remove and install Unity and the same with ubuntu-desktop, but no change. This is also a pretty common recommendation all over internet.- .Xauthority related solusions
Next step was to follow this advice entirely, but the output of both
ls -lah
andls -ld /tmp
checks out.Next step was this advice and it didn't do anything either.
I don't really understand what both this commands are trying to fix, but would be nice to understand that. Does someone have any further suggestions related to this? And does anyone have any explanation what they are supposed to fix?
- Installing
fglrx
Next step was to keep on guessing and this point I thought that the problem was graphic card related. I tried to Google around as much as I could about Radeon graphic cards and similar problems and found a solution that suggested:
sudo apt-get update sudo apt-get upgrade sudo apt-get install fglrx sudo aticonfig --initial sudo reboot
Well didn't do anything other than installing fglrx.
- So I'm looking for other solutions
This seems to be the four most common solutions to problems like this. I think it's time to at least stop suggesting anything related to
lightdm
because that doesn't seems to do the trick.As stated in comments this problem can be almost anything, but at least I tried to explain what I done so far. Have I done anything wrong? Are there anything more to know about these four?
-
younes over 9 yearsdid you try to go to another tty, and type
sudo pkill X
thengdm
and select it as default this way you might not get stuck on the login screen!! -
Panther over 9 yearsThis problem can be a result of many underlying causes. What have you done to try to fix it and can other users (make a new one to test if needed) log in ? Did you reset Unity ? We need a lot more information.
-
Lucas over 9 yearsYes. @bodhi.zazen I will edit my question with a better explanation.
-
Lucas over 9 years@younes Tried to switch to
gdm
as stated in my edit. Haven't triedsudo pkill X
but I do'nt think that will work either.
-
Lucas over 9 yearsThanks! But what to do if
ps aux|grep lightdm
gives me the output that a lot of instances using lightdm is still running? -
Ash over 9 yearsJust kill the instances using
sudo kill PID#
while PID# is the process number from the output (second column), use same command for all instances and runps
again to recheck, don't forget that withgrep
command you will always have one output which is the grep output so don't think this is an instance. And please accept the answer if it worked for you :D -
Lucas over 9 yearsDosen't seems to do the trick. Instances just pops up again. Output is the same as earlier, only with diffrent process numbers. Or am I looking at the wrong column or something stupid?
-
Ash over 9 yearsI'll try to provide the explanation with pics as soon as possible.
-
Ash over 9 years@Lucas please read the answer again, I edited it to show you an output sample.
-
Ash over 9 yearsSame error happens with me usually when X server is still running, try to
ps aux | grep X
(should be in the previous output but if it's there kill it two, remove.Xauthority
then runsudo lightdm &
again, if this doesn't work even after rebooting again and following the steps then I am sorry I'm totally out of ideas. -
Ash over 9 yearsplus check contents of /etc/profile file, if it contains export lines in the end (cuz of some installation that may broke the system) then comment them (using # at the beginning) then save and reboot, edit the file using
sudo nano /etc/profile
then after editing hitctrl+x
theny
and enter. -
Lucas over 9 yearsOutput is
Failed to use bus name org.freedesktop.DisplayManager, do you have appropriate permissions?
then blank for a while and finally[1]+ Exit 1 sudo lightdm
. Also some mix up happend in graphics. Suddenly the parts of the GUI was visible in tty. Logged in anyway. Tty and GUI stuck in same loop and the output is almost the same as the one stated here: itechlounge.net/2013/07/… So I guess there is a problem with HDD? I think your fix works fine, but there seems to more to it. -
Lucas over 9 yearsSorry for making comments a bot wierd. Incomplete message earlier. Will test what you suggested.
-
Ash over 9 yearsHope you can find a fix, and i don't think it's a HDD problem in the end, but I'm not that expert.