2

Fairly simple problem, but I am at a loss re how to debug or fix the issue.

I switched to Ubuntu (Wayland). Everything kinda works fine, but there are slight issues with a few programs, so logged out, clicked the gear icon to log back in using the default shell. And it just loops me back to login screen. I try a second time, and the machine locks. Tried logging in with compiz, exactly the same issue. The only option I can use is Wayland, it's been like this for the last month or so as I searched for and tried various fixes.

I've searched for similar issues on here, on Ubuntu/Linux forums and all solutions to similar issues are not fixing the issue. I really do not want to reinstall; it's a dev machine that I've quite carefully set up, and if at all possible I want to avoid doing that for a second time.

Edit: Ubuntu version is stock 18.04

5
  • Why is the only option that you can use is Wayland. Wayland isn't ready for prime time. Login loops can be caused by incorrect settings of two .*thority* files in your home directory. What version Ubuntu are you working with?
    – heynnema
    Dec 12, 2018 at 16:59
  • @heynnema regarding why the only option that works is Wayland — that's literally what my question is, if I knew then I wouldn't have the issue. The version is 18.04. The default login screen has two options for WM: Ubuntu, and Ubuntu (Wayland), and once the latter was selected, other options triggered the login loop. I understand what Wayland is, the reason I selected it in the first place was to check if it was functional.
    – DanCouper
    Dec 12, 2018 at 18:14
  • @heynnema I have one *thority file, .ICEauthority, (which shouldn't be relevant?). I was expecting an Xauthority dotfile for some reason, but there isn't one present.
    – DanCouper
    Dec 12, 2018 at 18:25
  • Does it meet any of the criteria in my answer? Otherwise, you may have something else going on... Nvidia drivers are notorious.
    – heynnema
    Dec 12, 2018 at 18:43
  • When is this bullsh*t ever going to stop 😜 It’s time you work together. We all want the same… Ubuntu is based on Debian, I got the same issue with an Ubuntu install 2 months ago
    – jaques-sam
    Feb 10, 2023 at 15:19

1 Answer 1

1

If you've been starting graphic applications from the terminal using sudo, that's what probably caused your problem. Always use sudo -H.

  • boot to the GRUB menu
  • choose Advanced Options
  • choose Recovery mode
  • choose Root access
  • at the # prompt, type:
    • sudo mount -o remount,rw / # remount the disk as rw
    • cd /home/your_username # change directory
    • ls -al .*thority* # list some files

You should see something like this...

-rw------- 1 your_username your_username 407910 Nov  2 08:56 .ICEauthority
-rw------- 1 your_username your_username     58 Jun 23  2017 .Xauthority

If it DOES NOT show -rw------- then...

  • sudo chmod 600 .*thority* # change file protection

If it DOES SHOW root root then...

  • sudo chown your_username:your_username .*thority* # change file ownership

  • reboot # reboot the computer

Reboot and see if you can log in.

Update #1:

We created a new "Guest" account, and it logs in fine. That confirms that there's something in the original account's home folder that's causing the login loop.

7
  • Ach, this is a good set of instructions, and I have been starting one specific application using the terminal, and there is a good chance that I've accidentally started it with sudo (thank you for the advice on that, just read up on the issues). But it's still not working. For starters, I don't have an Xauthority file, but notwithstanding that, I have a horrible suspicion that the root cause is Nvidia drivers: I have an MX150 card, and I installed the proprietary drivers straightaway when I switched the laptop to Ubuntu because the system wasn't picking the card up. Just purging them now
    – DanCouper
    Dec 12, 2018 at 21:30
  • @DanCouper please keep me posted. If it's working under Wayland, create a new user called... Guest. Log out. Log into Guest using Ubuntu (not Wayland), and see if the login loop occurs like it does on your normal account. This will eliminate 1/2 of potential software problems. Report back.
    – heynnema
    Dec 12, 2018 at 21:37
  • aha! Yes, this allows me to log in immediately. So with that in mind, I am assuming a rogue configuration in my home folder
    – DanCouper
    Dec 12, 2018 at 23:27
  • Also @heynnema this is, afaics, not Nvidia driver related: all the drivers and related bumph was purged, with no change to behaviour.
    – DanCouper
    Dec 12, 2018 at 23:29
  • Confirmed. The problem is in your normal account's home folder. I'd check the .bash* files, and the .config. folder. Backup .config to .config.BAK or .config.zip, then rename .config to .config.HOLD, then try to log in again.
    – heynnema
    Dec 12, 2018 at 23:39

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .