3

On login the password is accepted but I'm returned to the login screen. Tried multiple times even after reboot... same behavior.

I left my laptop (Lenovo Ideapad z510) in suspend mode (lid down) last night, but it did not resume this morning, as it usually does. It had shutdown or crashed, and on booting with Ubuntu the login failure mentioned above started.

cat ~/.xsession-errors
/usr/sbin/lightdm-session: 1: /usr/sbin/lightdm-session: ls: not found
/usr/sbin/lightdm-session: 104: exec: gnome-session: not found

Okay. I've tried a bunch of suggestions from Ubuntu gets stuck in a login loop

  1. Changed id to /usr/sbin/id in /etc/profile
  2. removed .Xauthority
  3. removed /tmp
  4. removed, purged and re-installed lightdm
  5. checked .profile for syntax errors (source .profile worked fine, so I guess no syntax errors)

Nothing worked.
My guest login is working fine, so another user should also work. I'm now going to create another user and continue working, but a solution to this problem is still warranted... it's likely going to repeat in future.

Installing and reconfiguring gdm also did not work.

sudo apt-get install gdm
kapilok
  • 131

1 Answers1

3

Resolved. There was a syntax error in .pam_environment. I missed out the DEFAULT in

PATH DEFAULT=${PATH}:${HOME}/MyPrograms

See Ubuntu help wiki page on environment variables

Zanna
  • 70,465
kapilok
  • 131