Installing or faking a x11 session
I have a headless Ubuntu-server running at work, and I connect to it from my home Windows machine through Putty. I've logged in with putty, and I need to run a program back at the server (a java package) but it won't run without an X11 display. This is the error I get:
No X11 DISPLAY variable was set, but this program performed an operation which requires it.
I've never used a remote graphical session before, so correct me if I speak nonsense. The thing is, I don't really need a gui to interact with this software, I just need it to run as if there was a gui. So, what's the easiest way for me to get it to run on the server via remote login? It can be an actual display session, or some kind of emulated display that the application could output to. The important is that I can start it from a command-line-only Putty window, and that it won't stop when I log off.
I read that xvnc
might do the trick, but I didn't get how to do it.
Was I clear enough?
Solution 1:
I recommend xvfb-run
which will fake an X server for the program you want to run:
nohup xvfb-run -a PROGRAM &