If you specify path directives, the paths are relative to the root path and results to synchronize only these subdirectories, not the whole directory specified in the root directive. But if you have not specified path directives, the directories in the root directives would be synchronized. Not just for the directives of the path, commands should make the file self-explaining. unison /var/To ensure the synchronization of server 1 and server 2, check the /var/that contains all settings that you will have to specify on the command line: nano /root/.unison/default.prf Note: Since this is the first Unison running, you will have to answer some questions. Next., check if the public key of server 1 is correctly transferred to server 2 or not: cat $HOME/.ssh/authorized_keys How to run UnisonĪt this point, you can run Unison for the first time to synchronize the /var/www directory on both servers. Then, copy your public key to ssh-copy-id -i $HOME/.ssh/id_dsa.pub # ssh-copy-id -i $HOME/.ssh/id_dsa.pub ![]() Run the following command to create a private/public key pair on and just hint Enter when you are asked. Let’s get started: apt-get -y install unison openssh-server ssh nano How to create a private/public key pair on server 1 To edit the files, you can install and use nano as the file editor on the shell. You are connecting from server 1 to server 2 via SSH, so the SSH packages are required. You should install Unison on server 1 and server 2. You will need to use two Debian servers and synchronize the directory /var/How to install Unison Unison would not act similar to simple mirroring or backup tools and is capable to deal with updates to both replicas of a distributed directory structure. You will see that files changed on server 1 will be replicated to server2 and vice versa. Join us with this article to learn setting up file synchronization between two Debian servers with Unison. Tutorial Files Synchronization Between Two Servers On Debian 10 With Unison ![]() How to create a private/public key pair on server 1. ![]() Tutorial Files Synchronization Between Two Servers On Debian 10 With Unison.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |