0

I have one NAS in India (active) and while other in US(passive).

I want to sync the US NAS with that of India in real time (with permissible latency)

I tried using RAID1 for this purpose, but I don't know how to use RAID on two network drives.

Is it even possible? If yes how? In no, how to achieve this?

4
  • 1
    For some definitions of "live" and "sync," it's possible, depending on things like available bandwidth and amount of data to transfer. But this is not done with RAID, because that's not how RAID works. Dec 3, 2014 at 15:37
  • What is the right way to do it?
    – Ut xD
    Dec 3, 2014 at 15:43
  • Depends on far too many variables to say without a lot more information. I'm gonna leave this open, in case one of our more storage-oriented users wants to take a crack at it, but it's pretty broad and there are a lot of ways to do it ... I don't think there's nearly enough in here about your environment to make a reasonably educated answer that isn't very, very general. Dec 3, 2014 at 15:48
  • Many NAS manufacturers include a backup/sync option (to a similar device) in their firmware. Beware that synchronization is not the same as a backup. Damage/delete the original and that action will be replicated too, leaving you with nothing.
    – HBruijn
    Dec 3, 2014 at 15:49

3 Answers 3

6

RAID is definitely not your answer. RAID is generally for drives being used in an array in the same physical location.

If you want to sync file systems across continents, then you need to use a NAS product that has some form of live mirroring capability. Most enterprise-class SAN/NAS products have this feature.

Otherwise, something like lsyncd or even a homegrown script to constantly rsync the two filesystems is probably your best bet.

1
  • 1
    The Ceph clustered file file system can do this. But in this case, you might want a solution from your NAS vendor. Details are always useful. Dec 3, 2014 at 16:46
2

DRBD is more or less a RAID1 implementation for block device replication over networks and does sync in real-time. For high latency/low bandwidth communication using a indirect setup using DRBD proxy is recommend.

When using DRBD over high latency, possible instable WAN connection, a active/passive (called primary/secondary in DRBD) setup is highly recommended - although dual-primary mode is theoretically possible when using a cluster file system like OCFS2 or GFS.

0

The thing you need to think about is how up to date you need both devices to be. The nearer you get to 'real time' sync, the more difficult and expensive it gets.

Fully synchronous replication options exist, but they're bandwidth intensive and very sensitive to network latency. I wouldn't normally suggest doing that on sites that are geographically distributed (as you are) because the performance will be horrible.

Of course, if your replication state is mandatory, then you'll just have to suck up the performance penalty.

However you can also do array or NAS level replication that's asynchronous - a lot of 'enterprise' NAS/SAN devices support doing so.

But actually, rsync is a fairly good tool for this job too - run it in cron at regular intervals, for example.

1
  • rsync seems to take ages. doing it at the moment. At least for 2 locally mounted nfs its terrible. I read its better of you sync against another host, but I havent got rsync to work against azure fileshare remotely.
    – The Fool
    Mar 1, 2022 at 20:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .