Friday, May 16, 2008

Sharing your keyboard and mouse

Because I have to administer a few Apple XServers, I need to keep a Mac around. Their server administration tools are (to my knowledge) closed source, and the command line tools are atrocious. We also have an XRAID, which I don't believe HAS any command line tools which with to administer it. So I need a Mac.


To this end, I have a 17" antique Powerbook that I keep around. It's big and clunky, and with only a gig of memory running Tiger, it's none too fast. I keep it around because I have to use the Admin Tools, and that's about it. It takes up a lot of room on my desk, and having to turn constantly gets irritating, so a while back, I found a Better Way(tm).


Enter Synergy. It's a client/server program that allows one computer's keyboard and mouse to act as others' inputs. Sort of like a software based KVM, without the V.


On my desktop, I type synergys, which starts the Synergy server. On the client machine, I type "synergyc newcastle". You must specify the server, since synergy can connect to multiple machines at once, which would be fantastic for a NOC team with shared computers.


The configuration is pretty simple. In Windows, there's a GUI, but in Unix, it's a simple config file.


Here's the content of mine:


bandman@newcastle[501]:~$ cat /etc/synergy.conf

section: screens
newcastle:
guiness.local:
harp:
end
section: links
newcastle:
left = guiness.local
right = harp
guiness.local:
right = newcastle
left = harp
harp:
right = guiness.local
left = newcastle
end

section: aliases
harp:
harp.int.ia
end

It's pretty straight-forward. In my example above, I have three machines. Newcastle is my linux machine, and the keyboard / mouse host. To the (physical) right of it is guinness, the mac. To the left of newcastle is (sometimes) another laptop called harp.

When I move my mouse off the right side of guinness, I want it to wrap to the left side of harp (or newcastle, if harp is gone), I specify that harp is to the right of guinness. Vice versa on the left.

Anyway, if you find yourself with too many computers and not enough inputs, give Synergy a shot. It's a great piece of software that I've given a couple of my users, and they love it.