Tuesday, December 17, 2013

Syncing code on multiple servers in real time 2



I have use 0.0.0.0 so that i can access it from any ip address available with the server like server haing 2 IPs and of course loop back
127.0.0.1
172.16.5.135
192.168.1.191

so it will be accessible from all three IPS.

and then user name and password and we are all set.

then browser enter the ipadress on which we have set the torrent sync.



In the above screen shot you can see the secrete keep it handy and install it and select the folder and append paste the secret  and all done within few minutes data start syncing.

Heavy problems Simple solutions if you like let me know. 

Syncing code on multiple servers in real time 1

Few days back my boss come up with a requirement of syncing on data across the servers .
it may happen that servers IP address can change as they ware hosted on Amazon.

As all of us know by default they don't provide us white(public )IP Address.so i start searching and was very much worried as syncing should be real time and i dont know on which server the data is going to sync.

i have googled a lot and then i read about the torrent sync. Its a very good open source software having great functionality.I really love it.

So lets start with installation.

Install

As its not directly available we need to add PPA first and then install it Per usual, setting up the Windows and Android clients is a fairly brainless process; setting up a Linux client is a little more exciting. Here’s what I did on my Ubuntu 12.04 server:

Set Up: We don’t set things up manually in Ubuntu, son!

Use the PPA:

$ sudo add-apt-repository ppa:tuxpoldo/btsync
$ sudo apt-get update
$ sudo apt-get install btsync

If you’re on a version of Ubuntu that didn’t come with add-apt-repository, you can grab it from the software-properties-common package.

When you do this you need to go through the following installation cycle and when you done you are all set repeat the same steps and data syncing start automatically




For me i have choose 12345 as a sync port you can peek any but its recommended to use port above 1024 as bellow 1024 all are well known ports