Header RSS Feed
 
If you only want to see the articles of a certain category, please click on the desired category below:
ALL Android Backup BSD Database Hacks Hardware Internet Linux Mail MySQL Monitoring Network Personal PHP Proxy Shell Solaris Unix Virtualization VMware Windows Wyse

X11 Forwarding through SSH not working (missing xauth)
Wednesday - May 28th 2014 - by - (0 comments)

Today I tried to launch jconsole on a remote server through a forwarded X session. But for some reason it just didn't work...

I did as always by connecting to the remote server with -X:

workstation ~ # ssh -X root@remoteserver

And then launched jconsole:

remoteserver ~ # jconsole &

... but nothing happened. I verified the /etc/ssh/sshd_config on the remote server side:

remoteserver ~ # cat /etc/ssh/sshd_config | grep X11For
X11Forwarding yes

And on the client side (my workstation) the /etc/ssh/ssh_config:

workstation ~ # cat /etc/ssh/ssh_config | grep X11
#   ForwardX11 no
# should not forward X11 connections to your local X11-display for
# keystrokes as you type, just like any other X11 client could do.
# file if you want to have the remote X11 authentification data to
ForwardX11Trusted yes

Both sides are correct... what is causing this?

I ran the ssh command again, this time in verbose mode and found the following error:

workstation ~ # ssh -X -v root@remoteserver
debug1: Entering interactive session.
debug1: Requesting X11 forwarding with authentication spoofing.
debug1: Sending environment.
debug1: Sending env LANG = en_US.UTF-8
debug1: Remote: No xauth program; cannot forward with spoofing.
X11 forwarding request failed on channel 0

Argh! The xauth package is missing on the remoteserver!

remoteserver ~ # apt-get install xauth

And then ran it again:

workstation ~ # ssh -X root@remoteserver

remoteserver ~ # jconsole &

Success:

jconsole through x-forwarding 

 

Add a comment

Show form to leave a comment

Comments (newest first):

No comments yet.

Go to Homepage home
Linux Howtos how to's
Monitoring Plugins monitoring plugins
Links links

Valid HTML 4.01 Transitional
Valid CSS!
[Valid RSS]

6939 Days
until Death of Computers
Why?