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:
No comments yet.
AWS Android Ansible Apache Apple Atlassian BSD Backup Bash Bluecoat CMS Chef Cloud Coding Consul Containers CouchDB DB DNS Database Databases Docker ELK Elasticsearch Filebeat FreeBSD Galera Git GlusterFS Grafana Graphics HAProxy HTML Hacks Hardware Icinga Influx Internet Java KVM Kibana Kodi Kubernetes LVM LXC Linux Logstash Mac Macintosh Mail MariaDB Minio MongoDB Monitoring Multimedia MySQL NFS Nagios Network Nginx OSSEC OTRS Office OpenSearch PGSQL PHP Perl Personal PostgreSQL Postgres PowerDNS Proxmox Proxy Python Rancher Rant Redis Roundcube SSL Samba Seafile Security Shell SmartOS Solaris Surveillance Systemd TLS Tomcat Ubuntu Unix VMWare VMware Varnish Virtualization Windows Wireless Wordpress Wyse ZFS Zoneminder