[torqueusers] Displaying X apps from a job
griznog at engineering.usu.edu
Thu Feb 16 15:02:45 MST 2006
On Thu, 2006-02-16 at 14:37 -0500, Troy Baer wrote:
> 1. The compute nodes may not have a route back to the user's
> workstation (particularly if they're on a non-routable private network),
> so they can't connect to the X display.
First, thanks for the response. You've given me some things to look at.
A given connection looks like:
PC <-> eth0:MASTERNODE:eth1 <-> NODE
eth0 has a public IP, eth1 is the internal private
(10.0.0.0/255.255.252.0) network. With my existing configuration I can
ssh from PC to MASTER then ssh from MASTER to NODE, start and X app and
it displays on PC.
What I can't do is:
ssh from PC to MASTER, submit job with X app and have job display on PC
So I know it's possible for something running on a NODE to display back
to PC, it just doesn't work through submitted jobs.
> 2. The user is logging into the login node in an ssh session, and the
> ssh client is not requesting an X pseudo-display. (This seems to be the
> default in recent OpenSSH release, and I'm not sure why.) If that's the
> case, the user would need to add the following to $HOME/.ssh/config on
> their workstation:
> Host name-of-login-node
> ForwardX11 yes
> # the following may also be needed to make things that use
> # X extensions like OpenGL/GLX work with recent OpenSSH releases
> ForwardX11Trusted yes
Both of these are yes in my current config and all /etc/ssh/ssh_config
specify X11Forwarding yes.
> 3. The user is logging into the login node in an ssh session with X
> forwarding enabled on the client side, and sshd either isn't creating an
> X psuedo-display at all or is attaching the X pseudo-display to
> localhost on the login node rather than a real IP address. (This is
> another odd default in recent OpenSSH releases.) To disable that
> behavior, set the following in /etc/ssh/sshd_config and restart sshd:
> X11Forwarding yes
> X11UseLocalhost no
I think you've hit the nail on the head here. It smells like passing
around localhost in my DISPLAY setting is the problem. Am I correct that
I need a submitted job to send the display back to
MASTER:ssh-tunnel-listening-for-X rather than localhost? I tried
'X11UseLocalhost no' but unfortunately that setting completely breaks X
over ssh everywhere. I went to all machines involved and ran 'xhost +'
and sniffed the exchanges to make sure iptables wasn't getting in the
so I think what I'm basically trying to get working is:
1. ssh forwards X from $DISPLAY at MASTER:nn back to PC
2. job starts X app on NODE and tells it to connect to MASTER:nn so that
display gets forwarded back to PC.
I guess theoretically 'X11UseLocalhost no' could solve my problem, if
only it didn't break everything :(
The last failed attempt I've made was to leave 'X11UseLocalhost yes' in
and have my job modify DISPLAY to point at the correct place:
#PBS -S /bin/bash
echo "We were given DISPLAY=$DISPLAY"
export DISPLAY=`echo $DISPLAY | sed -e 's/localhost/uinta-admin/'`
echo "We are using DISPLAY=$DISPLAY"
echo "Opening fluent..."
This fails with the standard "Error: Can't open display." message.
Basically I can get it to work anywhere except when starting the app
Thanks for your help,
More information about the torqueusers