Search code examples
ubuntusshputtygnome-terminalxming

Getting gnome-terminal via SSH and Xming


I'm running Ubuntu 16.04 in VirtualBox with a hosted network adapter, everything on Windows. I have set up openssh on Ubuntu listening to port 3220. I can log on successfully with PuTTY, I can run nautilus, gedit, etc. and get the GUI by Xming with no problem. Now when I run gnome-terminal I get an error

Error constructing proxy for org.gnome.Terminal:/org/gnome/Terminal/Factory0: Could not connect: Connection refused

I changed DISPLAY to several different possible values but none could work. Some SO answers suggest either :0 or :1. Someone else suggested putting IP address in front of the column symbol, and I tried all. The default value in my system is localhost:10.0.

My question is: There are 3 display "numbers" present in my setting. Xming claims its server at 0.0, PuTTY has a value in configuration (default when unset is :0), and Ubuntu (via SSH) has a variable DISPLAY. What are the relations between these numbers, and how should I coordinate them to get things work?


Solution

  • There has been a discussion in this issue. The following should work around the problem.

    dbus-launch gnome-terminal