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.

I am using the 13.04 x64 release of Ubuntu on my PC and at least it works so far as it should. But suddenly the lightdm crashes during boot and even if I try to start it manually from terminal after switching to another tty.

I don't know what may cause the problems because I didn't even install any graphics-drivers for my nvidia card (because I just know those problems since years and skip those problems by not installing any of them).

It worked fine for some days after fresh install and updates, but now it just does not what it should.

Switching to gdm did solve the problem logging in to my computer with a gui but hell this lightdm should work I guess..

The logs aren't pretty much of help for me but maybe someone know what's up?

lightdm.log

 [+0.00s] DEBUG: Logging to /var/log/lightdm/lightdm.log [+0.00s]
 DEBUG: Starting Light Display Manager 1.6.0, UID=0 PID=7369 [+0.00s]
 DEBUG: Loaded configuration from /etc/lightdm/lightdm.conf [+0.00s]
 DEBUG: Using D-Bus name org.freedesktop.DisplayManager [+0.00s] DEBUG:
 Registered seat module xlocal [+0.00s] DEBUG: Registered seat module
 xremote [+0.00s] DEBUG: Adding default seat [+0.00s] DEBUG: Starting
 seat [+0.00s] DEBUG: Starting new display for greeter [+0.00s] DEBUG:
 Starting local X display [+0.00s] DEBUG: Using VT 7 [+0.00s] DEBUG:
 Activating VT 7 [+0.01s] DEBUG: Logging to /var/log/lightdm/x-1.log
 [+0.01s] DEBUG: Writing X server authority to /var/run/lightdm/root/:1
 [+0.01s] DEBUG: Launching X Server [+0.01s] DEBUG: Launching process
 7376: /usr/bin/X :1 -core -auth /var/run/lightdm/root/:1 -nolisten tcp
 vt7 -novtswitch [+0.01s] DEBUG: Waiting for ready signal from X server
 :1 [+0.01s] DEBUG: Acquired bus name org.freedesktop.DisplayManager
 [+0.01s] DEBUG: Registering seat with bus path
 /org/freedesktop/DisplayManager/Seat0 [+0.61s] DEBUG: Got signal 10
 from process 7376 [+0.61s] DEBUG: Got signal from X server :1 [+0.61s]
 DEBUG: Connecting to XServer :1 [+0.61s] DEBUG: Starting greeter
 [+0.62s] DEBUG: Started session 7385 with service 'lightdm-greeter',
 username 'lightdm' [+0.64s] DEBUG: Session 7385 authentication
 complete with return value 0: Success [+0.64s] DEBUG: Greeter
 authorized [+0.64s] DEBUG: Logging to /var/log/lightdm/x-1-greeter.log
 [+0.64s] DEBUG: Session 7385 running command
 /usr/lib/lightdm/lightdm-greeter-session /usr/sbin/unity-greeter
 [+0.68s] DEBUG: Greeter closed communication channel [+0.68s] DEBUG:
 Session 7385 exited with return value 1 [+0.68s] DEBUG: Greeter quit
 [+0.68s] DEBUG: Failed to start greeter [+0.68s] DEBUG: Stopping
 display [+0.68s] DEBUG: Sending signal 15 to process 7376 [+0.82s]
 DEBUG: Process 7376 exited with return value 0 [+0.82s] DEBUG: X
 server stopped [+0.82s] DEBUG: Removing X server authority
 /var/run/lightdm/root/:1 [+0.82s] DEBUG: Releasing VT 7 [+0.82s]
 DEBUG: Display server stopped [+0.82s] DEBUG: Stopping seat, failed to
 start a display [+0.82s] DEBUG: Stopping seat [+0.82s] DEBUG: Seat
 stopped [+0.82s] DEBUG: Required seat has stopped [+0.82s] DEBUG:
 Stopping display manager [+0.82s] DEBUG: Display manager stopped
 [+0.82s] DEBUG: Stopping daemon [+0.82s] DEBUG: Exiting with return
 value 1

---

x-0-greeter.log

 Error writing X authority: Failed to write X authority
 /var/lib/lightdm/.Xauthority: Success

---

x-1-greeter.log

 Error writing X authority: Failed to write X authority
 /var/lib/lightdm/.Xauthority: Success /var/log/lightdm/x-1-greeter.log
 (END)

---

x0.log

 X.Org X Server 1.13.3 Release Date: 2013-03-07 X Protocol Version 11,
 Revision 0 Build Operating System: Linux 3.2.0-37-generic x86_64
 Ubuntu Current Operating System: Linux stefan-dev 3.8.0-30-generic
 #44-Ubuntu SMP Thu Aug 22 20:52:24 UTC 2013 x86_64 Kernel command line: BOOT_IMAGE=/boot/vmlinuz-3.8.0-30-generic
 root=UUID=6e9c6967-a55f-49b8-b690-7257b359ae8d ro quiet splash
 vt.handoff=7 Build Date: 17 April 2013  10:43:13PM xorg-server
 2:1.13.3-0ubuntu6 (For technical support please see
 http://www.ubuntu.com/support)  Current version of pixman: 0.28.2
Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version. Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown. (==) Log file: "/var/log/Xorg.0.log", Time: Tue Sep 17 18:27:30 2013
 (==) Using system config directory "/usr/share/X11/xorg.conf.d"
 Initializing built-in extension Generic Event Extension Initializing
 built-in extension SHAPE Initializing built-in extension MIT-SHM
 Initializing built-in extension XInputExtension Initializing built-in
 extension XTEST Initializing built-in extension BIG-REQUESTS
 Initializing built-in extension SYNC Initializing built-in extension
 XKEYBOARD Initializing built-in extension XC-MISC Initializing
 built-in extension SECURITY Initializing built-in extension XINERAMA
 Initializing built-in extension XFIXES Initializing built-in extension
 RENDER Initializing built-in extension RANDR Initializing built-in
 extension COMPOSITE Initializing built-in extension DAMAGE
 Initializing built-in extension MIT-SCREEN-SAVER Initializing built-in
 extension DOUBLE-BUFFER Initializing built-in extension RECORD
 Initializing built-in extension DPMS Initializing built-in extension
 X-Resource Initializing built-in extension XVideo Initializing
 built-in extension XVideo-MotionCompensation Initializing built-in
 extension SELinux Initializing built-in extension
 XFree86-VidModeExtension Initializing built-in extension XFree86-DGA
 Initializing built-in extension XFree86-DRI Initializing built-in
 extension DRI2 Loading extension GLX resize called 1680 1050 Server
 terminated successfully (0). Closing log file.
share|improve this question

3 Answers 3

Took me two days. Final solution:

  1. sudo dpkg-reconfigure gdm #select gdm
  2. sudo apt-get remove lightdm* --purge
  3. sudo reboot
  4. sudo apt-get install lightdm*
  5. sudo dpkg-reconfigure gdm #select lightdm
share|improve this answer
    
I'll give it a try this evening. –  Stefan Sep 18 '13 at 8:30
    
didn't work for me. –  Stefan Sep 19 '13 at 6:24
    
+1 Reinstalling lightdm got me back working (for 13.10 saucy salamander). I also reinstalled the unity-greeter (apt-get install unity-greeter) to restore the default login screen settings. –  squillman Nov 8 '13 at 15:34
    
lightdm is already prompted to be selected at step 4. –  Hongbo Zhu Apr 11 at 9:25

I've been having the same issue on Debian Sid and find removing the .Xauthority file rectifies it, although not a very reliable solution as I have had to do it every time I reboot, it's a workaround that enables me to get back to my gui.

Rename the file /var/lib/lightdm/.Xauthority to /var/lib/lightdm/.Xauthority-BAK

sudo mv /var/lib/lightdm/.Xauthority /var/lib/lightdm/.Xauthority-BAK

Restart lightdm service

sudo service lightdm stop
sudo service lightdm start
share|improve this answer
    
I appreciate your approach, thank you. But even though this may work (i have not tested it yet) I would then keep to gdm instead of having scripts removing other files just for a lightdm. anyhow thank you for your help! –  Stefan Sep 19 '13 at 13:37

I started experiencing this issue after applying the current lightdm patch last week. The greeter would fail to start due to lack of access to /var/lib/lightdm/.Xauthority, the result being a low graphic mode error which could only be resolved for one session by removing /var/lib/lightdm/.Xauthority. This issue seems to be caused by this new patch which gives the .Xauthority file much tighter permissions (600 rather than 664). See the following:

lightdm (1.6.0-0ubuntu3.1) raring-security; urgency=low

  • SECURITY UPDATE: wrong permissions on .Xauthority file (LP: #1175023)
    • debian/patches/07_xauthority_perms.patch: use g_open instead of g_file_set_contents in src/xauthority.c.
    • debian/patches/08_xauthority_fix_perms.patch: fix incorrect permissions left behind by previous versions in src/xauthority.c.
    • CVE-2013-4331

The suggested fix above seemed to work for about a half-hour until the old behavior returned, with the additional problem of stale .Xauthority files being left behind with 600 permissions in user home directories, causing graphical login loops.

To work around this issue, I have created a wrapper script for xfce-session-logout (I use XFCE) which removes .Xauthority from both user home directories and from /var/lib/lightdm. Since this script must use sudo to assume the correct authority to remove /var/lib/lightdm/.Xauthority, this is hardly ideal, although it works. Using gdm also avoids this issue. My situation is also complicated perhaps by the fact that I access the local system via the console and via xdmcp.

To address the security issue in the patch above, Ubuntu needs to patch whatever other programs (the greeters for example) need access to .Xauthority since currently by fixing the security issue, they have effectively broken lightdm. That is not very good.

share|improve this answer

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.