This is a write up on how to run barrier
(the synergy-core fork) on a headless raspberry pi. It's based on the work of hishamk, describing how to do the same thing for the original synergy.
If you're running multiple machines, none of them being the primary one, and you don't want to have the server machine running all the time just to share mouse and keyboard, this guide might be for you.
The keyboard still sends keys to the host system. I have to look into how to disable that.
I've read on some forums, that running barrier as service with root privileges is dangerous. So use at own risk.
I'm no linux expert. I just customized what I found over at hishamk's repo. For more technical details, please visit his repository.
apt update
apt upgrade
- Compile barrier. See their wiki for instructions.
- It's important that you compile using the Release build configuration. I couldn't find another way but to edit the clean_build.sh.
apt install xorg xserver-xorg-video-dummy
- Change hostname to beautify barrier config definition. Edit /etc/hostname accordingly
- Create barrier config and copy it to
/etc/barrier.conf
- You can create the config on your normal desktop pc. Make shure you convert the line endings to LF if you used a Windows machine to create the file. For some reason barrier didn't like CRLF.
- Run xorg and Barrier server:
X -config <path_to_your_dummy_config> && barriers -c <your_barrier_config> -f
- Copy
xorg_dummy.config
to/etc/X11/xorg.conf.d/
or whatever your distro uses - Copy
x_dummy.service
andbarrier.service
service files to/etc/systemd/system/
or wherever your systemd config resides - chown both to root:root - Reload systemd:
systemctl daemon-reload
- Start X dummy:
systemctl start x_dummy
- Check its status:
systemctl status x_dummy
- Start barrier server:
systemctl start barrier
- Check its status:
systemctl status barrier
- Enable both services to start persistently:
systemctl enable x_dummy.service
;systemctl enable barrier.service
- Reboot