Ubuntu 12.04 cannot login, bounces back to login splash

Asked by Tanmoy on 2012-05-16


I'm unable to login as a regular user after a reboot. At the lightdm splash screen, I type my password and hit enter. The screen flashes to console, then I'm thrown back to the login splash. I get the same results with kdm. (I have not been able to get gdm running to test it: the gdm splash never appears).

All packages are up-to-date.
Deleting ~/.Xauthority does not help.
Removing auto-updating wallpapers (gtk-sunlight) does not help.
I have 37 GB free in my home directory and 4 GB in /
I am not able to log in to gnome classic either (gnome-session-fallback)

I *am* able to log in as guest. I have a total of two user accounts and am also able to log in as the other user through lightdm, so I suspect there is something going on with the settings for my regular user.


I'm on a Dell Inspiron 1420 laptop.

Question information

English Edit question
Ubuntu lightdm Edit question
No assignee Edit question
Solved by:
Last query:
Last reply:
Barry Drake (b-drake) said : #1

You could carefully go through all the stuff in your faulty account (from the account you can access). It will take ages to find the faulty configuration file. You could start by getting rid of your .profile. My guess is that it would be easier to rescue any data you need from your old account and delete it.

Press CTRL+ALT+F1 and log in there and run:

sudo chown -R $USER:$USER $HOME

Then press CTRL+ALT+F7 and try to log in

Tanmoy (tanmoylaskar) said : #3

Right, I followed Barry's suggestion and somewhat painfully grafted my settings on to a new account, deleted the old account and renamed back to the old account. The system is back in working order, but the problem remains a mystery. It would have been interesting to try actionparsnip's suggestion first, but oh well!


Kostya Kovalskyy (kostyarjcnz) said : #4

Actionparsnip's solution worked! Thank you! But I have no idea how I changed permission on my account!

And if I had to reset my account each time I messed up something... well I would be using Windows by now. So you should have waited for solution a bit longer TanMoy!

If you don't use sudo for GUI programs you won't get this issue. Commands lke:

sudo gedit
sudo nautilus

will CAUSE this as it is not right. To run GUI apps with root access use:

gksudo gedit
gksudo nautilus

And it won't make an issue.

Jingru Luo (jingru-luo) said : #6

Thank you actionparsnip! The solution works for me!

Roman Kam (romankam) said : #7

Thanks for the info actionparsnip, it worked on my desktop.

Mother (dan-dpzimney) said : #8

actionparsnip's solution just work for me as well. Thank you! Also thank you for the insight on how to properly run GUI apps with root access.

i have similar problem , i used sudo chown -R $USER:$GROUP $HOME which works fine

Yuriy Nudelman (yuranu) said : #10

I had similar problem and actionparsnip's solution helped, thank you.
I am just curious, how does using sudo instead of gksudo cause the issue? What is the basic difference? Could somebody please explain?


GUI applications need more to be setup to run. Sudo is not suitable and is why gksudo (and kdesu in KDE) exists. Technically you can use gksudo for GUI and CLI commands. I like to correct people giving guides for things when they use sudo incorrectly. It means fewer people break their OS which in turn the community needs to spend more time fixing what is easily avoidable.

Marcus Pearlman (psucram1982) said : #12

Thanks actionparsnip for the solution and for the explanation for the cause of the problem. Here is the summary of what happened to me, which may be helpful to others: My problem occurred because I wrongfully edited /etc/X11/xorg.conf.

when I tried to restart X with sudo kill <X process ID> (usually this automatically restarts X for some reason) it failed.
sudo reboot, and i couldn't get the gui, the same error occured
 CTRL-ALT-F2 and corrected the xorg.conf file
 sudo startx, and then this login problem started,

 I could login to guest but not my account. I noticed that .Xauthority had root ownership. I tried actionparsnip's advice and everything works. I think the problem occurred because of the sudo startx, and this caused a change in ownership of the .Xauthority file. Am i right?

gksudo is the way to go :)

Yes. thats exactly it. gksudo for GUI apps and not sudo. Technically you can use gksudo for both.

teferra (teferra) said : #14

actionparsnip solution did not work for me. I get only a lot of Input/output error

Tom K. C. Chiu (tomchiukc) said : #15

I tried the method of actionparsnip but failed. Is there anyway I can check the possible cause, like log file?

Tom K. C. Chiu (tomchiukc) said : #16

I saw the command "sudo gdm start" in another answer and tried. It returns

gdm-binary[3050] : WARNING: GdmDisplay: display lasted 0.073876 seconds
gdm-binary[3050] : WARNING: GdmDisplay: display lasted 2.524756 seconds

and then it did not accept anything until I stopped it with Ctrl-Z.

Neil Devine (devine-neil) said : #17

actionparsnips solution worked for me too.

.Xauthority was the offending file for me. I'd been trying to install fglrx to resolve some overheating problems. Presumably amdconfig also changes the .Xauthority? Otherwise I don't know.

Roelof Kallenkoot (roelof000) said : #18

So I stumbled upon this issue aswell.
Tried rm ~/.Xauthority
and the sudo chown -R stuff .
Turns out I had installed NVM, the Node.js Version manager and it sourced it to my ~/.profile .

When I tool a look at my ~/xsession-errors it showed me that there was an error with the ~/.nvm/nvm.sh file ,
so I rm -rf ~/.nvm and lightdm worked again.

Brooks Childers (brooks-5) said : #19

I'm new to Ubuntu and I struggled for hours with CTRL-ALT-F1 (or F2 etc.) not working to get to a terminal I could use at the lightdm login screen like some posts say you can do. I have a Dell Inspiron 14R laptop, not sure why CTRL-ALT-F1 won't work. If you have this issue see http://askubuntu.com/questions/92556/how-do-i-boot-into-a-root-shell to get started. Once you get to a root shell (and if your a newbie like me the whole process starting with the recovery mode screen will look a bit scary as you do it) login to your normal account:

  login yourusername

You will need to provide your user password. This should give you a normal shell terminal. The root shell would not display the output of normal commands, like "ls". Not sure why. But when you login to your account the terminal behaves normally, you can use vi, etc. Removing .Xauthority did work for me. (Yeah!)

  sudo rm .Xauthority

Logout of your user account to get back to the root shell




to get back to the recovery screen, then proceed with normal boot. Initially I got a very low resolution Ubuntu desktop and my second monitor was not recognized. After a hard boot all returned to normal.

Not sure what caused my system to stop recognizing my login, but I've logged in and out a few times now and all seems well.

Cuneyt Baykal (cbaykal) said : #20

I am having a similar problem.
I have created another user account and I can login to that. But I could not copy my home folder to the new user account, as it asks for permissions. Also I cant use my programs in the new account.

How can I copy my folders without ruining everything? an easy way to do that?
How can delete the old one later and rename the new one as the old one? will this make my programs work back again?

Thanks a lot in advance

ksn (ksncool) said : #21


I followed actionparsnips suggestion, successfully login but horrible thing is my folders,data not found,my desktop is empty, other default folders(home-> {Downloads,Documents,Pictures etc) have not data and some installation not found(editor)
is there any way to get back my data?



I face the same problem. I did use sudo gedit, out of ignorance and now I am not able to login to my Unity from any of my accounts. I tried creating a new account and tried to login thru that, but it would still not work.

Request someone to help me out of this mess.


Vikas Jadhav (vjaihoo) said : #23

Since my machine was new I re installed unbuntu 12.04 on my laptop. I faced this problem I guess after I pressed update to 14.04 I guess...the update dosnt seem to have completed and I got stuck at login....did all changed user, used authority command etc etc what ever I could get from forum.....unfortunately there is nothing like talking and solving.....I DID NOT FIND ANY HELPLINE for UBUNTU USERS....very difficult to tackle problem......lot of suggestions are from Pros in Linux....like I never knew to press Shift and go to options of repair...somehow nobody mentioned this basic step......also struggled to get cursour to write and make changes....realised my Vostro keyboard I had to use FN and F1 while I was pressing cnrt+alt+F1.....Thanks
But I guess a dedicated helpline will be really useful or if some Linux champs can give their contacts...first time user really have some tough time getting used to Ubuntu/linix