Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Synching folders and files between two servers

Posted on 2014-07-10
22
Medium Priority
?
332 Views
Last Modified: 2014-08-05
Hi,
 
 I have a small number of files and folders on Server 1 in one location.
 I also have Server 2 in another physical location.
 Can you recommend either Free or Paid software where I can dump what is on Server 1 to Server 2 at scheduled times?

 Server 1 is a terminal server where users log in using Remote Desktop Connection program. In case Sever 1 is completely down or if there is a loss of electricity, I would like  the users to connect to Server 2 (Terminal Server) and at least have access to the information which may be day old or 1/2 day old (depending on how often I sync).

 I expect Server1 to be the main server and Server 2 to be the backup server where users can only look up the information until Server 1 becomes available.

Thanks.
0
Comment
Question by:sglee
  • 11
  • 10
22 Comments
 
LVL 5

Accepted Solution

by:
acesover2000 earned 188 total points
ID: 40189039
There are a couple 3rd party software products that will do this, but personally I recommend DFS (provided at least one of your servers is server 2008).  Sounds like you want to do a 1-way DFS replication (read-only) partner:

http://blogs.technet.com/b/filecab/archive/2009/01/21/read-only-replicated-folders-on-windows-server-2008-r2.aspx

and to restrict the schedule
http://msdn.microsoft.com/en-us/library/cc732278.aspx

But you may find after the initial sync the bandwidth requirements are not that great for a typical file share so you might want to remove the schedule after they are up to date.
0
 
LVL 12

Assisted Solution

by:Kent W
Kent W earned 1112 total points
ID: 40189127
A simple batch file using robocopy or xcopy, scheduled by task scheduler can absolutely do this free.
0
 

Author Comment

by:sglee
ID: 40189149
@mugojava

Yes I was thinking about using ROBOCOPY between Server1 and Server2 because it is FREE. (if I can't find no good software) But this requires a VPN connection between two servers (they are not on the same network/building), I was looking for a better & automatic solution.
0
NEW Veeam Backup for Microsoft Office 365 1.5

With Office 365, it’s your data and your responsibility to protect it. NEW Veeam Backup for Microsoft Office 365 eliminates the risk of losing access to your Office 365 data.

 
LVL 12

Assisted Solution

by:Kent W
Kent W earned 1112 total points
ID: 40189157
OH, not on the same network.  That's different.  
You could use a third party service...dropbox with the same account, a VPS in the cloud as a "meet in the middle" service, sugarsync...something of that nature.  Basically a meet-in-the-middle or yep, you'll have to do VPN.

Another direct option is if you have a router on the Server2 end you can set up a simple NAT to the file sharing and lock it to the presenting IP of Server1, that would also get you there, with a batch file tool.
0
 

Author Comment

by:sglee
ID: 40189414
Meeting in the middle is not an option. Cloud is not an option.
Keeping a VPN tunnel between two routers/locations is not an option.
Because of these restrictions, I am looking for a software solution - maybe some type of FTP software that runs on one server or both servers, at the scheduled time it will run the command like ROBOCOPY to keep other server in sync with the main one (server 1).
0
 
LVL 12

Assisted Solution

by:Kent W
Kent W earned 1112 total points
ID: 40189465
A little more background on your servers and network? If you can run FTP why not smb / NSF?  If you have to open a hole in firewalls you could just as easily open smb ports as FTP?  What is your constraining factor?
0
 

Author Comment

by:sglee
ID: 40189475
what is  smb / NSF? I am not familiar ... could you shed some light on the subject?
0
 
LVL 12

Assisted Solution

by:Kent W
Kent W earned 1112 total points
ID: 40189520
Samba or ms file sharing as Microsoft calls it is just the protocol you use when you are copying files via shares on ms windows boxes. If you open your smb port to each server on your firewalls you can copy files across just like they were on the same local network, from one server to a share on the other.   If you do have firewalls on each end, you can basically use anything you want. Just open the appropriate ports for the chosen protocol.  Your only constraint then would be bandwidth.  Robocopy is block level, so it will only copy files and parts of files that are different (unless the files themselves are encrypted).
0
 

Author Comment

by:sglee
ID: 40189534
Suppose that there is Server 1 with one public IP address and Server 2 at another public IP address, Both network have routers where port forwarding can be done.
With that said, can you give me some detailed steps that I can follow?
0
 
LVL 12

Assisted Solution

by:Kent W
Kent W earned 1112 total points
ID: 40189677
Are the public IPs directly on the servers or behind NAT or port forwarding?  What brand / model routers?  No brand does anything the same way.
0
 

Author Comment

by:sglee
ID: 40189772
Server 1 (192.168..2.10): ARRIS Cable Router (by WOW ) with port forwarding capability/NAT with internal IP 192.168.2.x network
Server 2 (192.168.1.6): WOW Cable Modem connected to CISCO 1811 with port forwarding /NAT with internal IP 192.168.1.x network.
0
 
LVL 12

Assisted Solution

by:Kent W
Kent W earned 1112 total points
ID: 40189792
I'm assuming you already have some kind of NAT setup for those private IPs for your servers to access from the outside.  You can use the same NAT that it sounds like you have RDP setup for.

On server 2, share the folder you want to sync.  Create an access rule to allow your Server1's presenting IP (the one it's natted to, or, if it's not natted, it will be the main public IP of your router at the Server1 location)  and allow that IP to access ports 137, 138,139, and possibley 445, allow TCP and UDP for all on the router at Server2's location.  Technically, 138 only needs UDP, 139 TCP, but it's easier, and you'll be locking it down to your servers IP.  
You should be able to browse to \\serverip\sharename on server2 FROM Server1.  You can even map it as a network drive, but that will be a bit "chatty", if you are being charged for bandwidth.
Now that you have access to the share across the wire, you can setup a copy script and fire it off however often you want with task scheduler.

What Server OS are these running?
0
 

Author Comment

by:sglee
ID: 40190178
Windows 2008 Servers on both.
Simple enough. I will try that and post the result.
0
 
LVL 12

Expert Comment

by:Kent W
ID: 40195750
Just checking to see if it worked for you?
0
 

Author Comment

by:sglee
ID: 40195785
Sorry I got side-tracked. I will try it and post the result.
0
 

Author Comment

by:sglee
ID: 40213288
Port Forwarding on the network that has SHARE Folder Network ErrorSorry for the late reply. I finally found the time to try this:
I followed your instructions, but it does not work. Here is what I did:
Network A: I have Windows 2008 Server (with IP address of 192.168.2.6) that has share folders for everyone with full permission.
In the router, I forwarded three ports 137(TCP),138(UDP), and 139(TCP) per your instructions.
Network B: on a PC, I opened windows explorer and typed \\IP address\Invoice. Then I got an error.

What have I done wrong?
0
 
LVL 12

Expert Comment

by:Kent W
ID: 40213296
What is the error?  Is the windows 2008 server on a domain?
0
 

Author Comment

by:sglee
ID: 40213367
ErrorPlease see the screenshot for error.
Yes It is Windows 2008 on a domain.
0
 
LVL 12

Expert Comment

by:Kent W
ID: 40214904
So sorry, I checked those last messages from my phone, and I didn't see the logs you had obviously posted.
I see you have firewall settings.  Did you open up access to the connecting IP to those ports also?  
You normally have to do that unless you place a computer, by IP,  in the DMZ.  That usually opens up everything, though, and not recommended.

The question is, are you making it through the router / firewall to the actual server2 at 192.168.2.6?  Try again and see if you are generating any log entries (failed audits / security entries) on the 192.168.2.6 machine.  
If you see nothing, I'd look at the firewall issue.  If you have a telnet client, or can install one on Server1, you can then telnet to port 139 at the public IP of your router and see if you get nothing or a connection.  You may not get any text, it may just drop to a black window. If you get "connection failed" in any way, you just aren't getting through the router / firewall.

First thing I'd check is your firewall rules to make sure you have allowed access.  Just mapping the ports is only 1/2 of the needed config.
0
 

Author Comment

by:sglee
ID: 40215270
Shared Folder and IP AddressPort ForwardingFirewall SettingsNetwork ErrorInstead of dealing with changes in Production server (Windows 2008), I decided to do it on my test Windows 7 PC.
I changed the port forwarding to the ip address of Win7 PC (192.168.2.120) and disabled windows firewall, and created a share "App" where everyone has Read/Write.

On a remote computer, I typed "\\public IP address" and \\public IP address\app" and I got a network error.
0
 
LVL 12

Expert Comment

by:Kent W
ID: 40215389
When I referred to "firewall" earlier, I was speaking of the firewall in your router.  Check it to make sure an external IP is allowed access TO your port forwarding rule.  Also, some of these routers have a config (normally a check box) to "block external requests", which means, regardless of firewall, it will block all traffic incoming that did not originate from the LAN side.  

Of course, the machine you are connecting to needs it's own internal firewall off. which it appears you have done.

Another note, on Windows 2008, "everyone" doesn't mean "everyone in the world", it means "everyone on my domain".
Not sure if it's part of and AD domain, but keep that in mind.  From the connecting server, you can mount a new drive and...I'm not sure if this is a feature they implemented in 2008, I know it's in Server 2012, while mapping a drive you can select "alternate credentials" and name any domain\user you want.
0
 

Author Comment

by:sglee
ID: 40220035
too complicated ... I give up.

Thanks for your help.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article is in regards to the Cisco QSFP-4SFP10G-CU1M cables, which are designed to uplink/downlink 40GB ports to 10GB SFP ports. I recently experienced this and found very little configuration documentation on how these are supposed to be confi…
Unable to change the program that handles the scan event from a network attached Canon/Brother printer/scanner. This means you'll always have to choose which program handles this action, e.g. ControlCenter4 (in the case of a Brother).
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…

580 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question