LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-19-2004, 03:29 AM   #1
kdotsky
LQ Newbie
 
Registered: Dec 2004
Posts: 4

Rep: Reputation: 0
not common x display question


I have an application that in order to work requires a window to be open. The problem is I don't want the window running on my local machine while logged in to the remote machine. I want to direct the display to the machine I'm logged into. I also need to have the program running after I disconnect (using nohup), which I currently can't do because the required window is runs on my local machine. I've tried setting $DISPLAY to :0.0, but I get a connection refused / no protocol specified error. I'm logging into a Fedora core machine from xmanager in windows. It's hard searching for a solution because all that comes up is how to setup the display so you can view it on your local machine, which is exactly what I don't want.


Thanks for the help!
 
Old 12-19-2004, 04:43 AM   #2
MartinN
Member
 
Registered: Nov 2003
Location: Ronneby, Sweden
Posts: 555

Rep: Reputation: 30
Hi kdotsky. Welcome to LinuxQuestions.org!

If I interpret your problem correclty, you log on from a remote host (using telnet or SSH or something like that) and then try to open a window on that machine. Is this correct? If so, this is what you need to do:

The user who logs on must
EXPORT DISPLAY=0:0
as you already tried. This is not enough, however, since the X server doesn't allow connections by default. You also need to look into the xhost command. The user who started X on the remote machine must issue a command like:
xhost +
This allows anyone to open a window on your display. Since this might be bad from a security perspective, you could arrange that only users logged on to the machine may open a window. This is done with the command
xhost +localhost

Does this answer your question? If not, I could try to clarify it for you.

Good luck!
Martin
 
Old 12-19-2004, 10:36 PM   #3
LinuxDave
LQ Newbie
 
Registered: Dec 2004
Posts: 21

Rep: Reputation: 15
There are 2 solutions to your problem:

1. You must be logged in at the remote machine, with a X server running. This will allow you to open a window on the remote machine. Or alternatively, someone else can be logged in, but must have run "xhost +" or "xhost +localhost".

The key is someone must be logged in on the remote machines console and running X.

2. You can run a vncserver on the remote machine. The vncserver will run on a display other than :0 (usually :1) and you can set DISPLAY=:1 to display the window. You can then run a vncviewer (from "remote" or somewhere else) if you want to see what's happening in your window.

LinuxDave
 
  


Reply



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
Common SuSE display issues. usaf_sp SUSE / openSUSE 12 06-19-2006 02:51 PM
BOGUS.common.04y -> /home/common/Mailbox jayakrishnan Linux - Networking 0 11-19-2005 04:48 AM
MOST common newbie question encore Linux - Newbie 4 03-06-2005 01:56 AM
Very common question regarding distros Kami.JZ Linux - Newbie 10 10-24-2004 09:16 PM
Common Question BajaNick Linux - Software 2 07-24-2003 11:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:36 AM.

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