The project has a new demand, in more than one app server randomly upload Pictures/resource files, one of the app needs to read the uploaded images, so that the previous rsync+inotify settings will not be able to deal with.So we study the next multi-directional trigger real-time synchronization mechanism, we can experiment, if there is inappropriate place, please contact me to amend, thank you.Here's the start.First, IntroductionUnison is a file Sync
also has a corresponding version under the Windows platform, such as Cwrsync and Sync2nas tools. The basic features of rsync are as follows: 1. Can be mirrored to save the entire directory tree and file system; 2. It is easy to maintain the original file permissions, time, soft and hard links, etc. 3. No special permission is required to install; 4. Optimized process, high file transfer efficiency; 5. You can transfer files using rsh, SSH, etc. , of
Original works, allow reprint, please be sure to use hyperlinks in the form of the original source of the article, author information and this statement. Otherwise, the legal liability will be investigated. http://hx100.blog.51cto.com/44326/612301I. Introduction of UnisonUnison is a file Sync tool that can be used under Windows, Linux, and other Unix platforms to keep content consistent between two folders (local or network). Unison has the same featu
compression transfer protocol similar to rsync.
2.2 install unison
Unison has a text interface and a graphic interface. Here we only show you how to use it on the text interface.
Download:
Http://www.cis.upenn.edu /~ Bcpierce/unison
In Windows, the file is a. exefile, And the
Inotify + unison implement bidirectional Real-time Data SynchronizationA new project was created a few days ago. The website architecture is that the front-end uses nginx to reverse proxy the two backend tomcat servers. At this time, the data between the two tomcat servers is synchronized in real time, which becomes a problem? I have searched for many solutions on the Internet. There are several methods for file synchronization under liux: 1. nfs for
Unison Introduction: two-way image synchronization tool that supports cross-platform synchronization. Unios can keep the content consistent between the two folders on the local disk and synchronize network data.
Features: cross-platform
1. No special requirements on kernel and User Permissions
2. Unison is bidirectional and can automatically update the two copies without any conflict.
3. Two methods, one is
I. Introduction of UnisonUnison is a file Sync tool that can be used under Windows, Linux, and other Unix platforms to keep content consistent between two folders (local or network). Unison has the same features as some other synchronization tools or file systems, but it also has its own characteristics:1. Cross-platform use;2. No special requirements for kernel and user rights;3.Unison is bidirectional, it
One: Unison introduction
Unison is a file synchronization tool available under Windows and UNIX platforms that enables two folders (local or network) to keep content consistent. Unison has the same characteristics as some other synchronization tools or file systems, but it has its own characteristics:
Cross-platform use;
No special requirements for kernel and
Introduction of Unison
Unison is a file synchronization tool available under Windows and UNIX platforms that enables two folders (local or network) to keep content consistent. Unison has the same characteristics as some other synchronization tools or file systems, but it has its own characteristics:
Cross-platform use;
No special requirements for kernel and us
Unison is a free and cross-platform file synchronization tool. With it, we can save two sets of file copies (instances) on two different platforms, or save it on different disks of the same system. Unlike a simple image method or backup utility, Unison can update two copies of the distributed directory structure at the same time. It can detect and display conflicting updates. Unlike distributed file systems
The servers are:Server a:192.168.1.6, synchronizing directory:/var/wwwServer b:192.168.1.7, synchronizing directory:/var/wwwInstall UnisonFirst install OCaml, version is at least 3.07 or higherDownload Address: http://caml.inria.fr
The code is as follows
Copy Code
Tar xvf ocaml-3.10.2.tar.gzCD ocaml-3.10.2./configureMake World optMake installCd..
Install UnisonDownload Address: www.seas.upenn.edu/~bcpierce/unison
" installation unison through the source package compiled installation unison, need objectivecamlcompiler. 1) Install OCaml to/USR/LOCAL/SRC (recommended version 3.0 above, installation path can be defined by itself) [[emailprotected]~]#cd/usr/ local/src[[emailprotected]src]#wgethttp://caml.inria.fr/pub/ distrib/ocaml-3.12/ocaml-3.12.1.tar.gz[[emailprotected]src]#tar-zxvf Ocaml-3.12.1.tar.gz[[emailprotected
Using unison+inotify to realize bidirectional real-time synchronization of dataEnvironment: Centos 6.5 64-bitserver1:192.168.1.201server2:192.168.1.250Requirements software: OCaml Unison inotifyI am all installed using Yum, if you like to use the source code compiled installation can download the source package.Yum Install OCaml unison inotifyThe first step : To
The installation of unison under MacOSX-Linux Enterprise Application-Linux server application information. The following is a detailed description. Unison is a cross-platform file synchronization tool that not only supports local synchronization, but also supports synchronization through network protocols such as SSH, RSH, and Socket. Unison supports both one-way
Bidirectional real-time data synchronization deploymentFirst add the server SSH trust, that is, the secret key loginweb1:192.168.10.36web2:192.168.10.37Execute the following commands on Web1 and WEB2, respectivelymkdir ~/.sshchmod ~/.sshGenerate RSA KeySSH-KEYGEN-T RSA(then three consecutive returns)Add the encryption key to the authorization key fileCd~/.sshSSH "-P" 192.168.10.36 cat/root/.ssh/id_rsa.pub >>authorized_keys #小写pSSH "-P" 192.168.10.37 cat/root/.ssh/id_rsa.pub >>authorized_keysScp-
The multi-machine data synchronization mechanism Unison + inotify-tools was accidentally encountered in the QQ group this morning when I heard a problem about two-way Real-Time Synchronization of different machines. When I thought of it, I found that the database (mysql ), it seems that the two-way real-time synchronization technology seems very limited, not to mention the need to achieve two-way Real-Time Synchronization of multiple machines, a varie
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.