Ever wished you could use your keyboard and mouse on another computer? In this article I will show you how.
To read it it should take about 60 seconds. In this time I’ll show you how to use one keyboard and mouse on two Linux machines. I’ll cover how to use the same keyboard and mouse on a Linux and Windows machine in another article.
Ready? Lets go!
First Decide which keyboard and mouse you want to use across multiple monitors on different machines and sit at that computer. The program needed to get this to work is called x2x.
As of this writing the stable version is 1.27
Download the stable version from http://x2x.dottedmag.net/
wget http://x2x.dottedmag.net/releases/x2x-1.27.tar.gz |
wget http://x2x.dottedmag.net/releases/x2x-1.27.tar.gz
Extract The Source code
Compile x2x
./configure && make && make install |
./configure && make && make install
If x2x compiled without any errors you should be good to run the program.
On the computer you want to use your primary keyboard and mouse on do the following:
Find out your IP
Run xhost to allow clients to connect to your display:
Going back to your original computer decide which side of the monitor you want your mouse to jump to the other computer on. It will either be North, South, East or West. If your second linux box is on your left like mine, it will be west.
Now lets get the two computers connected with the same keyboard and mouse:
x2x 192.168.X.X:0.0 -west |
x2x 192.168.X.X:0.0 -west
Thats all there is to it. You should be able to mouse over the right of your screen and see your mouse cursor on the other computer.