Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Problem launching program from terminal
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Valheru
Guru
Guru


Joined: 14 Mar 2003
Posts: 300
Location: Leeuwarden - The Netherlands

PostPosted: Thu Apr 10, 2003 10:28 pm    Post subject: Problem launching program from terminal Reply with quote

If I want to launch a program from the terminal, like qtella or the config program for imwheel I get this error :

Code:
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

Could not open display, check shell DISPLAY variable, and export or setenv it!


Mandrake didn't prepare me for this, how can I solve it without having to wade through any more man pages at 1 AM? I've been doing that all day and honestly don't feel like seeing another one...
Back to top
View user's profile Send private message
Jimbow
Guru
Guru


Joined: 18 Feb 2003
Posts: 597
Location: Silver City, NM

PostPosted: Fri Apr 11, 2003 12:16 am    Post subject: Reply with quote

Only the user who logged in is allowed to use X (by default). If you have changed users while logged into X then the new user will get an error message like that when trying to launch an X application.

There are two ways around this that I know of (I think there are probably others as well). If I am logged in as juser and I want to run an X application as root then I just
Code:
 sudo X-application &


You need the sudo package installed and configured to be able to do this. The other way is to issue
Code:
xhost +
as the original logged in user. This can be dangerous because it allows anyone access to your X-server even from remote machines so only do this if you are either not connected to the net or you are behind a firewall.
_________________
After Perl everything else is just assembly language.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum