Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 10-18-2004, 02:50 PM   #1
LQ Newbie
Registered: Mar 2004
Posts: 22

Rep: Reputation: 15
Gtk-WARNING **: cannot open display


I am using SUSE 9.1 and am having a peculiar problem that I don't understand.

If I log into KDE as user1 and run firefox (or any gui app) at the command line, no problem. If I "su - root", set DISPLAY=ipaddress_of_machine:0.0, I get a long wait and eventually an error

"Gtk-WARNING **: cannot open display"

The same happens when I log into KDE as root (run 'xhost +' just to be sure) and "su - user1", set DISPLAY=ipaddress_of_machine:0.0

If I don't set the DISPLAY variable, I get the error instantaneously, as one would expect. I don't know what else to look for and the long delay before the error makes me thing there may be something else wrong or something is not set up properly.

Old 10-18-2004, 03:03 PM   #2
Registered: Jul 2004
Location: Milpitas, California
Distribution: 1/2 Debian 1/2 my own
Posts: 189

Rep: Reputation: 30
It doesn't matter what display you set to use. What matters is the access control list (correct me if I'm wrong) of the XServer you're using. By default, whoever created the X session will be the only one who can use it. To allow other users to use the X server, you have to mess around with the xhost command. I'm lazy and just use xhost + which allows any client to connect.
Old 10-18-2004, 03:18 PM   #3
LQ Newbie
Registered: Mar 2004
Posts: 22

Original Poster
Rep: Reputation: 15
Hi bobwall

That was one of the first things I tried (see original post) which is why this is frustrating me so much. In all the time I have used Linux, "xhost +" and "DISPLAY=..." solved any display issues.

Any more suggestions?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Gtk-WARNING **: cannot open display gonzalo76 Slackware 18 12-12-2013 10:36 AM
Gtk-WARNING **: cannot open display iamjoepesci Red Hat 2 10-17-2008 11:51 AM
Gtk-WARNING **: cannot open display elfoozo DamnSmallLinux 3 07-12-2007 09:41 PM
Gtk-WARNING **: cannot open display: lijomali Fedora 6 11-10-2005 06:43 PM
Gtk-WARNING **: cannot open display: Larsin Linux - Software 1 02-25-2004 10:47 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:19 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration