[slurm-users] x11 forwarding not available?

Tina Friedrich tina.friedrich at it.ox.ac.uk
Tue Oct 16 02:47:21 MDT 2018


I had an issue getting x11 forwarding via SLURM (srun/sbatch) to work; ssh 
worked fine. Tracked it down to the host name setting on the nodes; as per 
RedHat/CentOS default, the hostname was set to the fully qualified. Turns out 
SLURMs X11 forwarding doesn't work with that; setting the hostnames to the 
short hostname made it all magically work. 

Tina

On Tuesday, 16 October 2018 09:29:01 BST Olivier Sallou wrote:
> On 10/16/2018 01:07 AM, Dave Botsch wrote:
> > Hi.
> > 
> > X11 forwarding is enabled and works for normal ssh.
> 
> I faced same issue, with ssh x11 working as expected on compute nodes,
> but not with slurm -x11.
> 
> I patched slurm locally to make it work.
> 
> what you can try to see if it is the same issue:
> 
> 
> srun -n1 --pty --x11 --pty bash
> 
> 
> # xterm
> // you should have an authorization failure error
> 
> // on connected node
> # xauth list
> 
> you will have a list of MAGIC COOKIE like
> 
> myslurmmaster/unix:10  MIT-MAGIC-COOKIE-1  YYYYYY
> myslurmnode/unix:52  MIT-MAGIC-COOKIE-1  XXXXXX
> 
> # echo $DISPLAY
> localhost:52.0
> 
> 
> To make it work manually I did (of course adapting node names and
> display port number):
> 
> xauth remove myslurmnode/unix:52
> xauth add localhost:52.0
> 
> then xterm (for example) worked.
> 
> If this is the same problem, slurm can be easilly patched to work (can
> give you how)
> 
> Olivier
> 
> > Thanks.
> > 
> > On Mon, Oct 15, 2018 at 09:55:59PM +0000, Rhian Resnick wrote:
> >> Double check /etc/ssh/sshd_config allows X11 forwarding on the node as it
> >> is disable by default. (I think)
> >> 
> >> 
> >> X11Forwarding yes
> >> 
> >> 
> >> 
> >> 
> >> Rhian Resnick
> >> 
> >> Associate Director Research Computing
> >> 
> >> Enterprise Systems
> >> 
> >> Office of Information Technology
> >> 
> >> 
> >> Florida Atlantic University
> >> 
> >> 777 Glades Road, CM22, Rm 173B
> >> 
> >> Boca Raton, FL 33431
> >> 
> >> Phone 561.297.2647
> >> 
> >> Fax 561.297.0222
> >> 
> >>  [image] <https://hpc.fau.edu/wp-content/uploads/2015/01/image.jpg>
> >> 
> >> ________________________________
> >> From: slurm-users <slurm-users-bounces at lists.schedmd.com> on behalf of
> >> Dave Botsch <botsch at cnf.cornell.edu> Sent: Monday, October 15, 2018 5:51
> >> PM
> >> To: slurm-users at lists.schedmd.com
> >> Subject: [slurm-users] x11 forwarding not available?
> >> 
> >> 
> >> 
> >> Wanted to test X11 forwarding. X11 forwarding works as a normal user
> >> just ssh'ing to a node and running xterm/etc.
> >> 
> >> With srun, however:
> >> 
> >> srun -n1 --pty --x11 xterm
> >> srun: error: Unable to allocate resources: X11 forwarding not available
> >> 
> >> So, what am I missing?
> >> 
> >> Thanks.
> >> 
> >> PS
> >> 
> >> srun --version
> >> slurm 17.11.7
> >> 
> >> rpm -qa |grep slurm
> >> ohpc-slurm-server-1.3.5-8.1.x86_64
> >> ...
> >> 
> >> 
> >> --
> >> ********************************
> >> David William Botsch
> >> Programmer/Analyst
> >> @CNFComputing
> >> botsch at cnf.cornell.edu
> >> ********************************
> >> --
> >> ********************************
> >> David William Botsch
> >> Programmer/Analyst
> >> @CNFComputing
> >> botsch at cnf.cornell.edu
> >> ********************************


-- 
Tina Friedrich, Snr HPC Systems Administrator, Advanced Research Computing
Research Computing and Support Services, Academic IT 
IT Services, University of Oxford 
http://www.arc.ox.ac.uk



More information about the slurm-users mailing list