I observed a strange behaviour on my new XUbuntu installation.

==== Background:

I had the intention of experimenting two different remote desktop solutions (one at a time); the local computer (display/keyboard/mouse) had to be a Windows machine, the remote computer (apps) had to be XUbuntu:

  • VNC

  • remote X Server (XMing on Windows + XDMCP on XUbuntu)

I am an (old) newbie, and I was planning to experiment without SSH tunneling, behind my modem/router, for sake of simplicity in the beginning; to add SSH (and enforce tunneling) later, before opening an access from the general Internet.

I could not find any simple recipe on the web (many throwing inside SSH from the beginning, none specifically addressed to lightdm)

=== What I did:

I defined my fresh XUbuntu installation for one user without the need of logging in; and this was working normally. Via the GUI I added a second user (with the vague idea it could help soon or later). As first experiment I copied the file /etc/lightdm/lightdm.conf to /etc/lightdm/lightdm.conf.my, edited the copy, ensured the two files had same owner/group and access right and then "renamed" (mv) /etc/lightdm/lightdm.conf to /etc/lightdm.conf.orig and /etc/lightdm/lightdm.conf.my to /etc/lightdm/lightdm.conf.

I did so to avoid to alter the original file. Rebooted the system. System did not reach the graphic run level. It was anyway possible to login in text mode. Tried startx.

I can't remember exactly what happened then. Anyway I was not happy and I tried to go back: renamed the files in the opposite direction in order to revert to the original setup. Reboot.

==== What I got:

The system was not restored to its original behaviour. It was displaying the graphic login window (this was not the original behaviour). Anyway the user proposed at login was correct. I Typed the password. After some seconds the graphic login reappeared without any error message. With control-alt-F1 I got the textual login again, and there I was able to login (with the same username/password "failed" in the graphic login). Tried this again (reboot / graphic login) with same result. Rechecked the mentioned configuration files.

==== Question: What could have happened to change the System behavior, even if I restored the previous configuration files? Note that I did no other modifications, not messed up password etc etc; as far as I understand the presence of additional files in the Desktop (I have parked there a copy of the file extracted from /usr/share/doc/lightdm/lightdm.conf) should not disturb in any way; and also additional files not ending in ".conf" in the folder /etc/lightdm (I have left there some) should not disturb...

Additional question: where can I find some explanation of the concept of "Seat" (a keyword that appears in the lightdm conf files)?

==== Additional info:

I am not sure if the modification I tried in the /etc/lightdm/lightdm.conf make sense; again I think this should be immaterial after the operated restore; anyway: I had tried to add the following lines:



  • Did you really "try startx" or did you maybe try sudo startx? when logged in at the Ctrl-Alt-F1 virtual terminal, type ls -l ~/.{ICE,X}authority and add the result to your question please – steeldriver Jun 22 '15 at 22:56
  • Typing the command that you suggest I get "-rw------- 1 root root 5708 giu 22 12:53 /home/xyz/.ICEauthority" and "-rw------- 1 root root 408 giu 22 12:53 /home/xyz/.Xauthority" – ginsi Jun 23 '15 at 5:53
  • As far as I remember I forgot to prefix "sudo" in the first attempt but I did "sudo startx" after the "not permitted" message. – ginsi Jun 23 '15 at 6:07

The actual problem is almost certainly unrelated to the lightdm.conf file.

Desktop sessions (or X sessions more generally) always belong to a user, and should never be invoked using sudo: doing so almost always results in a root-owned .Xauthority file, which can't subsequently be updated by the normal login / session startup process.

Either delete the file from your virtual terminal login session

rm ~/.Xauthority

(it will be regenerated on next successful session startup) or take ownership of it using

sudo chown $USER:$USER ~/.Xauthority

then try GUI login again with the restored conf file.

  • WOW! your diagnosis was correct and your solution worked! Thank you very much, steeldriver! Surely I would have never found this by myself, and I learned something in the meanwhile. After the chown command, when I rebooted, I got an error related to a greeter, but the problem was transitional, and after a second reboot it did not happen again. Perfect. (I think I am supposed to "accept" your answer now, but I was not able to find how to do it. Suggestions?); ah, OK, found and done... – ginsi Jun 23 '15 at 15:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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