Sign in to follow this  
FlamingOyster

Mirroring Two Servers, Running Btsync?

Recommended Posts

Hi there.

 

I'm wondering if it's possible to have two servers (in two different locations) that are mirrored, so that you would only have to set up the folders on one of the servers, instead of having to do it on both?

 

I realize there's probably going to be some manual work that has to be done on both servers, but it would be awesome if after that, you would only need to access one of the servers.

 

 

Best regards

Edited by FlamingOyster

Share this post


Link to post
Share on other sites

Hi,

I currently do that for 2 Apache servers for WordPress and owncloud. The MySQL database is not synced with btsync though. I use the MySQL sync mechanism for that (2 way).

So far works fine for me :-)

Share this post


Link to post
Share on other sites

Hi,

I currently do that for 2 Apache servers for WordPress and owncloud. The MySQL database is not synced with btsync though. I use the MySQL sync mechanism for that (2 way).

So far works fine for me :-)

Hi,

 

That sounds awesome.

 

So you can actually just login to the BTSync Web UI on one of the servers, add a folder and that same folder will be added to the second server?

Share this post


Link to post
Share on other sites

So you can actually just login to the BTSync Web UI on one of the servers, add a folder and that same folder will be added to the second server?

No, Sync won't automatically create folders on your second server, UNLESS they're within a folder you're already syncing.

Example 1:

You're already syncing a folder named "A" between two servers. On one device, you add a new folder named "B" within folder "A" - this will propagate to the other device

Example 2:

You're already syncing a folder named "A" between two servers. On one device, you add a new folder named "B" outside of folder "A", and add this new folder to Sync on that device - the folder will not be automatically created/added to Sync on your other device

Share this post


Link to post
Share on other sites

No, Sync won't automatically create folders on your second server, UNLESS they're within a folder you're already syncing.

Example 1:

You're already syncing a folder named "A" between two servers. On one device, you add a new folder named "B" within folder "A" - this will propagate to the other device

Example 2:

You're already syncing a folder named "A" between two servers. On one device, you add a new folder named "B" outside of folder "A", and add this new folder to Sync on that device - the folder will not be automatically created/added to Sync on your other device

It's not what I'm looking for.

 

It's like having two drives running Raid 1, but instead having two servers who are 100% identical. Is this possible with BTSync?

 

Or do I have to add a key on server 1 and then do the same on server 2?

Share this post


Link to post
Share on other sites
Guest idef1x

you might get something working with syncing the config file (dump sample config), add the folders /keys in it and use some scripting to change the node name or so, cause I don't think they can be the same. start btsync with this config and monitor it for changes, and restart btsync for the changes to take affect.

but how many times would you add a folder anyway, so I don't think it's worth the effort

Share this post


Link to post
Share on other sites

...having two servers who are 100% identical. Is this possible with BTSync?

You'll never achieve a "100% identical" "mirror/clone" from one server to another using Sync - the reason being that Sync needs to maintain a unique database of files on each device (so it knows what's in sync/what isn't on that particular device, etc)

Going back to your original post, it depends precisely what you're trying to "mirror" between servers? If it's just websites, then you could simply add you "/wwwroot" or "/htdocs" folder (as appropriate) to Sync, and that will then sync everything within that to your other server - including sub folders (everything, that is, that's accessible - i.e. not open/locked/in use by other processes).

However, as sjoerd points out, this will only sync physical files/folders - it won't "mirror" MySQL databases, etc

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this