5/9/2023 0 Comments Linux daemon sync![]() To make the Syncthing daemon start automatically, we can use Systemd, which is the Linux init manager. The output of the command above is the following: syncthing To gather information about the service, and see what ports are included in it, we can run: $ sudo firewall-cmd -info-service=custom If we want to add the service to a specific zone, we should specify it with the -zone option, passing the zone name as argument. Notice that with the command above, since no zone is specified, the service will be added to the “default” one. If using Firewalld, to activate the service, and thus to enable traffic through the required ports), we should run: $ sudo firewall-cmd -permanent -add-service=syncthing & sudo firewall-cmd -reload ![]() Recent versions of the Firewalld and Ufw firewall managers, already come with a pre-configured service for Syncthing (here with the word “service” we mean a defined set of rules). Setting up the firewallīefore we run Syncthing, for it to work correctly, we must setup some firewall rules in order to allow incoming traffic through certain ports. If we are using Debian or Ubuntu, we can also add the official repository to our software sources, and then install it using apt. We should download the archive containing the version compatible with the architecture of our system. The second method of installing Syncthing consists into downloading the dedicated Linux tarball from the downloads section of the official site. Obtaining the software it’s just a matter of launching our terminal emulator and run: $ sudo pacman -Sy syncthing On Archlinux we can use pacman to install the syncthing package, which is part of the “Community” repository. On Debian and its many derivatives, instead, we can run: $ sudo apt install syncthing To install Syncthing on Fedora, we can use the dnf package manager, and issue the following command: $ sudo dnf install syncthing This is always the recommended way to obtain software the only problem is that, especially on distributions like Debian “stable”, the repository can contain outdated versions of the packages. Syncthing is available in the native repositories of the most used Linux distributions, such as Fedora, Debian/Ubuntu, and Archlinux, therefore we can easily install it with our favorite package manager. Additionally, only if using Debian or Ubuntu, we can add the official Syncthing repository as an additional software source and install the package from it. Sent 61 bytes received 12 bytes 146.There are basically two methods we can use to install Syncthing in our favorite Linux distribution: we can use the version packaged in the native repositories, or we can download a tarball from the official Syncthing website. Wed Feb 2 04:24:13 2022 Normal: Calling rsync with filter-list of new/modified files/dirs Wed Feb 2 04:23:06 2022 Normal: Startup of "/tmp/test/" finished: 0 Wed Feb 2 04:22:52 2022 Normal: recursive startup rsync: /tmp/test/ -> Permanently added ':6765,:6765' (ECDSA) to the list of known hosts. settings Īnd after 4 hours of wandering: Wed Feb 2 04:22:52 2022 Normal: - Startup, daemonizing. Open /etc/nf and comment out the default configuration using - at the beginning of the line and add below configuration to the file. Generate ssh-key in both the servers and add to authorized_keys file. # yum -y install lua lua-devel pkgconfig gcc asciidoc lsyncd Install below packages on both the servers. There is a good tool called lsyncd to sync files between multiple servers on real time basis. Realtime File synchronisation between multiple servers in multi master mode
0 Comments
Leave a Reply. |