Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I'm brand new user in MacOSX. I'm using ssh to connect to some Linux servers. I'm trying to open a GUI locally for a process running in the remote Linux server.

So I read that I should install XQuartz which is used for the X11 in the Mac.
I installed it but when I try to start the GUI I get error that DISPLAY is not set.

Indeed when I echo DISPLAY, nothing has been set. Am I supposed to set something manually?

I also noticed that there is some command line as part of the XQuartz installation. Am I supposed to use only this command line? When I start it and echo DISPLAY I see just :0.0. How can I configure this?

I tried ssh -X to connect and additionally I also checked out the X-11 FAQ According to this something overrides my DISPLAY on the local machine. I suspect that TextMate which I installed previously does this, but I'm not sure how can I override it. What should I set? What is: /tmp/launch-Bh0fLm/:0?

share|improve this question
    
:0.0 normally refers to the host graphics adapter. I ssh and ssh -X into my server at work (to ubuntu from ubuntu) and in both cases echo $DISPLAY returned localhost:10.0. I do frequently launch gnome apps from remote machine via ssh command line. IMHO, investigate as much as you can about remove X sessions in Mac OSX. Sorry, I don't know more. –  Chris K Jun 30 '13 at 22:11

1 Answer 1

up vote 1 down vote accepted

Try the following on your Mac OSX system:

Enable X11 Forwarding with the “X11Forwarding yes” option set in /private/etc/sshd_config for your SSH daemon's own local X11 host. This will allow the Mac OSX host to receive X11 client requests back from the remote machines (Linux) through ‘ssh‘ with the -X option set.

Then restart sshd on the Mac OSX host:

Under System Preference / Sharing pane on Mac OS X. The SSH daemon should be running on the remote machine as well!

share|improve this answer
    
The SSH daemon should be running on the remote machine as well! What do you mean?If I am connected via ssh to the remote machine then it should be already running, right? –  Jim Jul 11 '13 at 20:26
    
@Jim - yes that comment means what you said. It was only meant as a reminder, but given you're connecting to the Linux boxes it's moot. –  slm Jul 11 '13 at 21:06

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.