Monday, June 10, 2013

A small problem and some solutions

by Tracyanne

A couple of weeks ago my primary computer's video card died, it had been displaying signs that it was on the out for a while, but it finally gave up the ghost and refused to display anything intelligible, so now it's in the workshop waiting for a new card to arrive from Taiwan.

In the mean time I've resurrected my partners old laptop and installed the hard drive from my machine into it. This required that I reinstall the OS as my machine is 64 bit , and this machine is 32 bit. However there are a few small problems, the display on my partner's old machine has missing pixels and a few missing keys, and the sound doesn't seem to work.

My initial solution to this problem was to use my net book connected to an external monitor and accessing the other machine via X over SSH. In that manner I have a fully functional keyboard and can view the desktop on a large high resolution monitor (1920x1080).

When using X over SSH my desktop looks like this:
With the net book's panel at the bottom and the panel from the other computer's desktop at the top. I'm running Ubuntu Studio with LXDE on the net book and Linux Mint KDE 32 bit on my partner's old machine, but I've installed XFCE panel for this exercise. The email client's GUI is being accessed over the network.

I've was told that VNC is faster than X over SSH, so I decided to try VNC. For my purposes it's not necessary to tunnel VNC over SSH, as it is all operating over my LAN, so I haven't bothered with that set up.

I installed several different VNC servers and clients, until I found a combination that I was happy with. With the server running on the other computer and the client running on my net book.

My desktop looks like this:

This is the desktop of the other computer, the VNC client is set to display at full screen with a resolution of 1920x1050 (on 1920x1080 resolution monitor). To access the desktop of the net book I have to run the VNC client at a smaller resolution, and not utilise full screen in the VNC client.

From my perspective, there are a few issues with VNC.

  1. I can't use VNC at full screen, if I want to also access the desktop of the net book.
  2. I'm not seeing any performance gains, over my LAN, and the display shows obvious refresh activity, which leads me to believe displaying a full desktop over a network may actually be slower than displaying the content of a single window, as X over SSH does.
  3. I have noticed that one or the other of the two machines, appears to lose connection with the Wireless LAN, often enough that it causes problems for both X over SSH and VNC, with the problem magnified by the need to refresh the display in the client periodically, when using VNC.

Based on my experiences with VNC and X over SSH, I think I prefer X over SSH, it seems to recover from the momentary drop outs better than VNC. However, neither seems to provide me with the elegant solution I am looking for.

I remembered another potential solution to my problem, and after some searches on the Internet rediscovered Synergy -

Synergy is an application that enables Mouse and Keyboard sharing between several computers over a network. It it cross platform, so runs on Linux, Mac and Windows. The only potential drawback is that each of those computers must have it's own monitor. Fortunately I have a spare monitor with 1680x1050 capability, which I set up on my desk so that I have 2 monitors, one above the other, with the 1920x1080 monitor connected to my net book on top.

I installed Synergy 1.3.8, but this version proved to be very buggy,. Every time I used a Control key, such as SHIFT or CTRL while I was using the client machine, the synergy client would crash, and I would have to restart it after physically attaching a mouse and keyboard to the machine. Running the 1.3.8 version of Synergy client as a daemon with –restart enabled made no difference.

After some more Internet research I discovered that there is a fixed version of Synergy 1.4.10 available in the Ubuntu 12.04 (Precise Pangolin) backports, so I upgraded both the server (my net book) and the client machine to Synergy 1.4.10. Now it works correctly and I can use the Control keys.

My Desktop looks something like this:

Top Monitor:

Bottom Monitor:

This set up works quite well, although if I shut down the client machine I do have to move the keyboard connector (USB) to a USB port on it, in order to Log In.

The Synergy client starts Automatically on start up. I added the command

synergyc --restart --daemon brenda

to Session and startup. As does the Synergy Server with

synergys -c /home/tracy/.synergy/synergy.conf

added to Session and Startup on the server machine (my net book).

This arrangement works very well for my purposes. The only other issue I had was accessing files on the client machine. This I achieved using SSHFS on the server to access the client machine's file system over SSH. I had been doing this when using X over SSH.

It looks something like this:
I will most likely connect the two machines via ethernet, as there are still drop outs occasionally (most likely the net book). Though they do not appear to affect the stability of the system.

Enhanced by Zemanta


Post a Comment