Syncthing-inotify on Ubuntu 16.04

Right now syncthing-inotify does not have a ppa, so it must be installed manually.

Note: FreeBSD instead has a port available

1 – Download systemd service from:

2 – Fetch latest binary and move it to proper path

wget https://github.com/syncthing/syncthing-inotify/releases/download/v0.8.7/syncthing-inotify-linux-amd64-v0.8.7.tar.gz
tar zxvf syncthing-inotify-linux-amd64-v0.8.7.tar.gz
chown root:root syncthing-inotify
mv syncthing-inotify /usr/bin/syncthing-inotify

3 – Before starting, increase available max_user_watches

# check how many available
sysctl fs.inotify.max_user_watches
fs.inotify.max_user_watches = 8192

# change them once rebooted
echo "fs.inotify.max_user_watches=204800" | tee -a /etc/sysctl.conf

4 – Enable service and start

systemctl enable syncthing-inotify@www-data.service
systemctl start syncthing-inotify@www-data.service

5 – Check status

systemctl status syncthing-inotify@www-data.service