LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
LinkBack Search this Thread
Old 02-03-2012, 12:38 AM   #1
shaze
LQ Newbie
 
Registered: Dec 2003
Posts: 9

Rep: Reputation: 0
X11 Forwarding problem


We have several serves which users log-in to and run X sessions. For some of them X fails withe message

Cannot connect to X server localhost:10.0.
Check the DISPLAY environment variable or use `-d'.
Also use the `xhost' program to verify that it is set to permit
connections from your machine
.

For others, it works fine. I cannot see what differs between the machines that work and which don't.
  • These machines all run Scientic Linux 5.4.
  • We try to keep the same config and software on all though over time there has been some divergence.
  • In particular, I have checked that /etc/ssh/sshd_config is exactly the same and /etc/X11 seems the same on both working and non-working machines.
  • X11Forwarding is set to "yes".
  • The same version of openssh-server is running and I have tried to compare what X11-related packages have been installed on both working and non-workig machines and can't see anything obvious.
  • None of the machines are running any firewalls, nor the local machines
  • The local machines have been a variety of different machines (different OSes too)
  • Using -X or -Y with SSH we get a DISPLAY variable of localhost:10.0 which seems right on both the machines where X works properly and where it doesn't.


Any ideas of where to go on this would be gratefuly received

Thanks

Scott

Last edited by shaze; 02-03-2012 at 12:39 AM. Reason: typos
 
Old 02-03-2012, 02:30 AM   #2
lithos
Member
 
Registered: Jan 2010
Location: SI : 45.9531, 15.4894
Distribution: CentOS, OpenNA, trying desktop Fedora & openSuse
Posts: 854

Rep: Reputation: 133Reputation: 133
Hi,

this thing X over SSH bothers me too, but sometimes this happens
Quote:
Cannot connect to X server localhost:10.0.
and it was related to something on client machine not running something (I don't know if it's initx or something like that) that would accept X screen from 'server' to client machine.

Sometimes the quickest solution was "export DISPLAY=ip_of_client_machine:0.0" and it worked.

Last edited by lithos; 02-03-2012 at 02:31 AM.
 
Old 02-03-2012, 01:12 PM   #3
shaze
LQ Newbie
 
Registered: Dec 2003
Posts: 9

Original Poster
Rep: Reputation: 0
Thanks for the reply, but it unlikely the client machine (or I suppose technically the X server -- the local machine). From my laptop I can ssh into one machine and it works fine; if I ssh into another it doesn't. As I say there is not firewall on any of the machines. The same thing applies using other machines too.

Also have tried setting the DISPLAY variable locally. No luck. Also done an xhost +
 
Old 02-03-2012, 03:47 PM   #4
lithos
Member
 
Registered: Jan 2010
Location: SI : 45.9531, 15.4894
Distribution: CentOS, OpenNA, trying desktop Fedora & openSuse
Posts: 854

Rep: Reputation: 133Reputation: 133
I'm sorry

but try reading this post
if you will maybe find anything useful
 
  


Reply

Tags
ssh forwarding, x11 forwarding


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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] X11 forwarding problem over ssh. Where DISPLAY is set? kaz2100 Linux - Software 3 09-27-2009 05:32 AM
Strange networking problem: connectivity lost when using x11 forwarding Selene Debian 2 10-06-2008 01:53 PM
X11 Forwarding Oxagast Linux - Software 1 09-02-2008 03:14 AM
X11 Forwarding BlueTornJacket Linux - Server 11 03-12-2007 05:00 PM
x11 forwarding problem with Gtk nocturna_gr Linux - General 4 03-05-2006 04:42 AM


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

Main Menu
 
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
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration