Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

When I try to login using Ubuntu(Default) session, I am unable to login. After giving password I am getting this message on screen

Unable to launch "gnome-session --session=ubuntu" X session --- "gnome-session -session=ubuntu" not found; falling back to default session.

However, I am able to login using Ubuntu Studio Session or Xfce Session or using CTRL+ALT+F1.

I have tried with no success to

  • Rename / remove .Xauthority
  • Chown username:username .Xauthority
  • Using gdm ( I was not able to see login screen after using gdm as default and rebooting. I was just seeing blinking cursor)

ls -lah reveals

-rw-rw-r-- 1 username username   0 Jan 8 10:39 .Xauthority
-rw-rw-r-- 1 username username  38 jan 7 16:17 .xsession
-rw------- 1 username username 418 jan 8 10:39 .xsession-errors
-rw------- 1 username username 418 jan 8 10:39 .xsession-errors.old

Contents of .xsession-errors/.xsession-errors.old are as follow

Unable to launch "gnome-session --session=ubuntu" X session --- "gnome-session -

session=ubuntu" not found; falling back to default session.
sudo: no tty present and no ask program specified
Script for cjkv statrted at run_im.
Script for default started at run_im.
Script for cjkv statrted at run_im.
Script for default started at run_im.
/home/username/.xsession line 1: /usr/bin/gnome-session: Permission denied

Permission for /usr/bin/gnome-session are as follow

-rw-rw-rw- 1 root root 236k Mar 21 3013 /user/bin/gnome-session

Please help in this regard.

share|improve this question

2 Answers 2

up vote 1 down vote accepted

You seem to have done all the hard work of diagnosing the issue: /usr/bin/gnome-session needs to be executable

sudo chmod +x /usr/bin/gnome-session

However I strongly advise you to investigate how the permission got changed, and whether there are other system files that have been affected.

share|improve this answer
    
Thanks. I was able to log in again. I was in middle of upgrading via terminal then I stopped that. Can you please guide how to investigate about "How the permission got changed" ? –  azeem Jan 8 at 1:45

In "-rw-rw-rw- 1 root root 236k Mar 21 3013 /usr/bin/gnome-session" the "-rw-rw-rw-" means that nobody can execute gnome-session. It should be "-rwxr-xr-x". In order to set it to that, do sudo chmod 755 /usr/bin/gnome-session

If that does not work, the following solves a tremendous number of gnome / X11 / graphics related issues:

sudo apt-get reinstall --purge ubuntu-desktop

This will reinstall lightdm and unity and purge their configuration. You can then choose to use gnome 3 instead of unity by selecting it when logging in.

You can also switch from lightdm to gdm by running: sudo dpkg-reconfigure lightdm

share|improve this answer
    
Thanks for kind response. Did you mean chomod 755 or chown 755 ? –  azeem Jan 8 at 1:46
    
Chmod! Chown would try to set the owner of that file to the user 755...It might not complete it, as there is usually no user 755, but make sure it is chmod 755.. –  RPi Awesomeness Jan 8 at 3:52
    
@RPiAwesomeness: Thanks. chmod worked fine. –  azeem Jan 8 at 5:17
    
Yes, chmod, sorry for the typo. –  Enigma Jan 8 at 14:04

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.