0

I have a Linux (Ubuntu) VM in which I am trying to run the xterm command to get extra terminal windows. The VM is hosted on my Windows 10 machine, which is able to SSH into the VM (via Putty, Ubuntu bash, Cygwin etc.)

I am trying to use X11 Forwarding to get the xterm command to work. Right now I'm encountering two problems:

1) When I SSH to the VM via "ssh -Y user@hostname" (on the Ubuntu bash shell), I am able to enter the VM, but I encounter the warning message "Warning: No xauth data; using fake authentication data for X11 forwarding."

2) When trying to run xterm on the VM, I encounter the error

"X11 connection rejected because of wrong authentication.
xterm: Xt error: Can't open display: localhost:10.0"

I've seen some solutions but am unsure whether I should be implementing them on the host (Windows) machine or on the VM.

Also, Xming is active on the Windows machine. I was in fact able to get X11 forwarding to work before, but something happened (I don't know what I did) that caused it to stop working.

How would I go about trying to fix this?

EDIT: I would like to clarify that xterm DOES work for Putty. That is, if I use Putty to SSH (with X11 enabled) into my VM, then I can run xterm. However, it doesn't work for the Ubuntu bash. So the problem is with Ubuntu bash, but I am unsure how to fix it.

  • 2
    When you refer to "Ubuntu bash shell", do you mean Windows Subsystem for Linux ? – steeldriver Jun 2 '18 at 18:26
  • When you SSH from bash are you logging in as the same user that's logged into the X11 session? For instance, if you log in to your desktop/window manager in the VM as user "foo" and then log in via SSH as user "bar" (with X11 forwarding), "bar" won't be able to run an X11 application without "foo" first allowing authentication using xauth. – Emmanuel Rosa Jun 2 '18 at 18:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.