Wednesday, December 01, 2010

A screen-like command for X applications

The screen command has been very useful for running programs on remote machines because you can detach the sessions and log out of the remote machine and the application is still running remotely.

It would be nice to do that with a graphical application since you can connect to a remote graphical application via X or VNC or similar applications, any graphical application terminates when you close the session.

That's changed with xpra. Connecting to an X server (the special Xvfb server, basically an X server minus any video drivers so it can run on a headless computer -- yes, X with no video card) as a compositing window manager on the remote computer allowing you to log in later (even from a third computer), re-attach the session and the program is still running.

The parent project that includes xpra is partiwm, a tiling window manager.

Compiling and Installing on Mandriva Linux

To install the dependencies, the README.xpra offers advice for Debian-based distros and Fedora. For Mandriva, it's

# urpmi xorg-x11-Xvfb python-pyrex libx11_6-devel libxtst6-devel libXcomposite1-devel libXdamage-devel pygtk2.0-devel gtk2-devel

I was asked to select an appropriate version of aspell and choose either or ctagsemacs-extras (pygobject2 is included in pygtk2.0 for
Mandriva). This installed 115 packages, about 130+ MB of stuff.

*** STANDARD COMPILATION HERE ***

All the files you need are installed in /install. You can tar this directory and scp it to a remote computer and install xorg-x11-Xvfb, GTK2 and pygtk2.0. The two computers need to be running close to the same version of Python or you might have problems from different versions of X libraries.

RESOURCES
xpra on Freshmeat
The most current release is March 22, 2009. In addition to bugfixes, support has been added for full clipboard sharing plus application icons are included.

 Window Switch
 WinSwitch is a GPL3-licensed continuation of the above project focusing only on the remote windows application. As of this writing (December 2012), the most current packages are dated October 2012. Downloads for multiple Operating systems are available, including Android and a Java client. None of the RPM packages are compatible with my current Mageia2 system, so compiling from source is in order.

No comments: