You are not logged in.

#1 2015-11-24 03:04:49

hagabaka
Member
Registered: 2010-12-15
Posts: 34

[SOLVED] Cannot start any X program without rebooting

After I leave the computer for a while and come back, sometimes I will be unable to start any X application. It says "Protocol not specified. Unable to open display :0". Qt and GTK applications print a slightly different error with similar content. I often find this when KDE screen locker is about to kick in, and the result is that I can't interact with the desktop, and in the journal kscreenlocker_greet just keeps dumping core. But sometimes this happens without screen locker too, and it doesn't always happen when I lock the screen or locking automatically happens, so it doesn't seem like kscreenlocker is the culprit.

I've searched about the error message, and found a lot of results about running X applications under root or on a remote server. I haven't been doing either of these. I'd really appreciate help with debugging this problem.

Last edited by hagabaka (2015-11-25 01:31:54)

Offline

#2 2015-11-25 01:31:23

hagabaka
Member
Registered: 2010-12-15
Posts: 34

Re: [SOLVED] Cannot start any X program without rebooting

I found the answer:

I closed the laptop lid and opened it which triggered the problem, and when looking at the journal, I noticed that the latest lines have "localhost.localdomain", while the lines before the lid close have just "localhost". When I set the hostname back to "localhost", I was able to open X applications right away. NetworkManager was setting the hostname when it reconnected, because I forgot to put something in /etc/hostname.

Offline

#3 2015-11-25 01:32:03

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: [SOLVED] Cannot start any X program without rebooting

Please remember to mark your thread as [Solved] by editing your first post and prepending it to the title.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

Board footer

Powered by FluxBB