How do I increase the inotify limit to get my filesystem watcher to work?
You are probably reading this because you encountered the following error with the filesystem watcher on linux:
Failed to start filesystem watcher for folder yourLabel (yourID): failed to setup inotify handler. Please increase inotify limits, see https://docs.syncthing.net/users/faq.html#inotify-limits
Linux typically restricts the amount of watches per user (usually 8192). When you have more directories you need to adjust that number.
On many Linux distributions you can run the following to fix it:
echo "fs.inotify.max_user_watches=204800" | sudo tee -a /etc/sysctl.conf
On Arch Linux and potentially others it is preferred to write this line into a separate file, i.e. you should run:
echo "fs.inotify.max_user_watches=204800" | sudo tee -a /etc/sysctl.d/90-override.conf
This only takes effect after a reboot. To adjust the limit immediately, run:
echo 204800 | sudo tee /proc/sys/fs/inotify/max_user_watches
Add user to sudoers, under root:
usermod -aG sudo user
Install the SSH server:
sudo apt intall openssh-server
Install UFW to allow access to port 22:
sudo apt install ufw
Allow port 22 through the firewall:
sudo ufw status
sudo ufw allow ssh
sudo ufw enable
Allow port 80 and port 443 through the firewall to manage GLPI from the browser:
sudo ufw allow http
sudo ufw allow https