ubuntu 14.04 login loop problem

133,206

Solution 1

You can either create a new user as suggested by ColonelTrogdor or there are other ways to solve this problem. First login into tty by pressing CTRL+ALT+F1

Note: Press ALT+F7 to come out from tty

Solution 1: Reset the Unity and Compiz

  1. Download Unity Reset tool from here.

    Note: It should work with Ubuntu 14.04, 13.10 and 13.04.

  2. Reset Unity using the following command

    $ unity-reset
    

Solution 2 (Most Recommended): Reinstall Ubuntu Desktop (i.e Unity)

sudo apt-get install --reinstall ubuntu-desktop

Solution 3: Install other Desktop Environment like,Gnome, KDE..etc

Now, I suggest you try Gnome Desktop. It also looks cool.

sudo apt-get install gnome-shell ubuntu-gnome-desktop

After trying any solution, just reboot your system.

$ sudo reboot

Solution 2

I have tried all sorts of things from the forums to fix my login loop problem. None of them worked. I ended up figuring out a less than optimal solution, but one that worked (which makes it preferable over everything else I tried). This is what I ended up doing:

Open Virtual Terminal: Ctrl+Alt+F1

Logged in using my user account. It let me log in there, even though it did not in the GUI.

Since none of the other solutions worked, and the most important thing to me was to have a usable account with admin privileges, I did the following:

sudo adduser newusername

You will have to fill out all the details, including password and such. Then, to give it root privileges:

sudo usermod -a -G sudo newusername

Now hit Ctrl+Alt+F7 to switch back to the GUI. You may need to reboot to get everything working properly. The GUI let me log in to the new user I had created.

If you need items from the old user's home folder and it refuses to allow it due to permissions issues, you can open a terminal (or hit Ctrl+Alt+F1 again) and change ownership, thus granting these permissions, with:

chown newusername:oldusername ~oldusername

Note: You may have to decrypt the old user's home folder if you had chosen to encrypt it when you set it up

Solution 3

Today I (apparently) experienced the same problem using a system administrator UID. I tried logging in with a non-admin UID on the console. Success. I remotely logged in with the admin UID and this was my session:

Last login: Fri Jul 3 16:55:22 2015 /usr/bin/xauth: /home/kingb/.Xauthority not writable, changes will be ignored kingb@North40:~$ ls -l .Xauthority -rw------- 1 root root 317 7月 2 08:36 .Xauthority

I changed owner and group to the admin user and can now log in with the admin account.

The only thing I can offer which may have caused this is as follows:

  • I was logged in as the above admin user on the console.
  • A few days later I discovered the console session frozen.
  • I found that I could remotely log in as the admin user and rebooted the machine.
  • Days later I experienced the problem that brought me to this page.
  • ls -l .Xauthority for a non-admin user revealed the owner and group inconsistencies.

No telling what actually caused the symptom (frozen console session?) but (for me) the fix was simple enough.

Solution 4

I had this issue today on 14.04LTS, but found the root cause to be an issue with permissions on my user directory getting mistakenly altered.

The symptoms for me: Login screen would show up, allow be to login, successfully logged in, started to load, then black screen for a second and back to the login screen. The only thing in vim /var/log/syslog that looked suspect was:

Dec  9 13:50:31 pc-host pulseaudio[5505]: [pulseaudio] core-util.c: Home directory not accessible: Permission denied
Dec  9 13:50:33 pc-host gnome-session[5280]: WARNING: IceLockAuthFile failed: Permission denied

Solution:

  • Press Ctrl+Alt+F6 and log in
  • Run command: sudo chown myusername. /home/myusername
  • Press Ctrl+Alt+F7
Share:
133,206

Related videos on Youtube

Anitha
Author by

Anitha

Updated on September 18, 2022

Comments

  • Anitha
    Anitha over 1 year

    My Ubuntu 14.04 is stuck when trying to login my desktop. The screen goes black and soon after that the login screen comes back.

    I followed all steps in Ubuntu gets stuck in a login loop but the issue was not solved.

  • Anitha
    Anitha about 9 years
    I uninstalled combiz. But still unable to log-in @Ganesh
  • 智障的人
    智障的人 over 8 years
    Note - sometimes CTRL ALT F1 won't work. In that case, try CTRL ALT FN F1.
  • Manny265
    Manny265 almost 8 years
    solution 2 seems like the best especially when u change ownership of .Xauthority and it is still not working
  • Sandeep C
    Sandeep C over 7 years
    Solution 2 has worked for me always.
  • Amit Patel
    Amit Patel over 5 years
    Solution 2 worked. Thanks!!