How to handle multiple locations, multiple machines and multiple OSes.

Status
Not open for further replies.
Joined
Feb 11, 2018
Messages
4
Hello,
I have been trying to collect information on threads on individual topics, but I am afraid I am not seeing clearly the big picture with my installation.

I have two (possibly more in the future) locations, each one with its own FreeNAS server. In all locations, I have both Windows and Linux machines. The locations are connected with a site-to-site VPN, but the connection speed is only decent (let's say 10-15 Mb/s). Except in rare occasions, files are not added or modified very frequently, and are almost never modified synchronously in both locations.

Ideally, I would like the two NAS to give quick read and write access to the data, transferring in the background the changes to NAS in the other location for backup and later usage of the files. More simply, I would like the system to act as Dropbox synchronising the files in a NAS rather that individually on each computer. For conflict resolution, I would gladly accept a read-only lock on the non-currently-used NAS that last as long as all the modifications are not fully transferred.

I tried to create Linux datasets, shared with NFS, but I did not manage to make them work on Windows. Since then, I created Windows datasets shared with SMB and things are working well. This thread https://forums.freenas.org/index.php?threads/dataset-share-type-purpose.34809/ contains an interesting discussion on using different sharing protocol (for example NFS and SMB) on the same dataset, but it is not very clear to me whether that is OK or not, and how permissions would be handled in that case. First question. Should I stick to ACL and SMB for all systems, or ACL shared with SMB for windows and with NFS for linux, or away from ACL for what is explained in the following point?

Since I need two-ways synchronisation, I first thought to use an rsync task, hoping that it would not take too long to run (https://forums.freenas.org/index.php?threads/replicating-data-between-2-freenas-installs.57785/, https://forums.freenas.org/index.php?threads/best-way-to-sync-two-servers.48064/). Unfortunately, I recently realised from the documentation that ACL permissions are not preserved. Second question. Could this be a satisfactory solution, and should therefore migrate the existing datasets away from ACL (see previous point) to try it out?

As discussed in the previous links, the best way to synchronise datasets would be through the replication task, which unfortunately is one-way only. Let's give a few names for simplicity. Imagine a work location, with a work dataset, and a home location with a home dataset. Clearly work dataset would be replicated in the home NAS and work dataset in the work NAS. Third question. Should I share home in the home location, work in the work location, and have that access to the off-site dataset is done through the network (no conflicts, but poor throughput). Should I instead create a read-only share for home on the work NAS, so that I can read quickly, while still having to go through the network for editing (no conflicts, high read throughput, poor write throughput, confusing for the user)?

Final question. Is there no better options than:
- rsync on non ACL partitions
- replication and having to access shares through the network

Thanks a lot.
 

kdragon75

Wizard
Joined
Aug 7, 2016
Messages
2,457
It would depend on the type of files, how there used, and home many people at each site will access the data at the same time. Is any of the data site specific? Sound like you want DFS.
 
Joined
Feb 11, 2018
Messages
4
Hi. Most files are PDF, a few MB each. Then there are music files, pictures, some videos. Nothing really specific. As access, we are talking about 3-4 people max at each location. Most of the time, not both locations at the same time.

As for DFS, do you mean the Microsoft one or DFS as a concept? Any suggestion for which implementation? Any chance FreeNAS supports that?
 

Chris Moore

Hall of Famer
Joined
May 2, 2015
Messages
10,080
Final question. Is there no better options than:
- rsync on non ACL partitions
- replication and having to access shares through the network
If you are doing some form of replication, the thing that will get you into a bind is if someone edits a file at one site and someone else edits the same file at another site. Then you have two different files wit the same name and when the system tries to sync, you stand a chance of loosing one of them. I don't have a suggestion for a fix if you absolutely need the same file available at multiple sites.
The DFS (Distributed File System) that @kdragon75 mentioned might be a solution but the only version of that I am familiar with is from Microsoft:
https://en.wikipedia.org/wiki/Distributed_File_System_(Microsoft)
 

Chris Moore

Hall of Famer
Joined
May 2, 2015
Messages
10,080
It would depend on the type of files, how there used, and home many people at each site will access the data at the same time. Is any of the data site specific? Sound like you want DFS.
If the sites will not be editing the files simultaneously, then you have options like rsync to keep the servers synchronized with each other. Do you need instructions on setting that up?
 
Joined
Feb 11, 2018
Messages
4
If the sites will not be editing the files simultaneously, then you have options like rsync to keep the servers synchronized with each other. Do you need instructions on setting that up?
I considered rsync but I understood it does not work with ACL (https://forums.freenas.org/index.ph...rmissions-support-for-windows-datasets.43973/). To try it out, I would need to convert the current Windows datasets into Linux datasets. Then, either try again to have windows connect to a NFS share, or to have the SMB share work with Unix permissions. Unfortunately I have limited experience with these last two cases.

Do you think rsync would give satisfactory results, considering I only have a few hundred GB of data? Also, do you have any suggestion on which route to take for sharing (SMB share on Unix permission or windows connect to a NSF share)?

Thanks a lot!
 

Chris Moore

Hall of Famer
Joined
May 2, 2015
Messages
10,080
To try it out, I would need to convert the current Windows datasets into Linux datasets. Then, either try again to have windows connect to a NFS share, or to have the SMB share work with Unix permissions. Unfortunately I have limited experience with these last two cases.
No. I don't think so...

The post you pointed to was from 2016 and I don't know if the situation has changed at all and honestly, I never saw that thread before.
Personally, I don't use any fancy permissions on my SMB shares or ACL (Anterior Cruciate Ligament?) whatever that is, but I rsync between my two FreeNAS systems that I access with Windows. Never had any problems with it. I don't know what the fuss is about.

Now, the difference for me, I only do a one way sync where I push data from the Main NAS to the Backup NAS because I don't make changes on the Backup system, I only make changes on the Main NAS.
This is a link to the instructions I followed to set it up: http://thesolving.com/storage/how-to-sync-two-freenas-storage-using-rsync/
Just ignore where they talk about "pull" because that doesn't work, at least it didn't when I set it up initially and I have not tried to change it because, it works and I don't want to break it.
Take a look at it and think about if it can work for your usage.

PS. You can setup push on both systems. I had to switch operations to the backup one time when the primary was down and to get the primary updated when it was working again, I disabled the rsync on the primary, set it up on the backp and pushed the changes from the backup back to the primary. Then, when I was ready, I switched the direction again by disabling the rsync on the backup and enabling it on the primary and having all the users point at the primary instead of using the backup.
I also had a situation where I needed a to move data both directions and I did that by creating a separate dataset. I created the same dataset on both systems and created a second rsync task that copied data from the backup to the primary on the 'Transfers' dataset where the main dataset was still going the other direction, from the primary to the backup. That allowed me to sync in both directions and I had a separate SMB/CIFS share for each dataset.
Maybe this will help.
 
Joined
Feb 11, 2018
Messages
4
The post you pointed to was from 2016 and I don't know if the situation has changed at all and honestly, I never saw that thread before.
Personally, I don't use any fancy permissions on my SMB shares or ACL (Anterior Cruciate Ligament?) whatever that is, but I rsync between my two FreeNAS systems that I access with Windows. Never had any problems with it. I don't know what the fuss is about.
Hi Chris. I found the link to the thread in the Rsync task documentation (http://doc.freenas.org/11/tasks.html#rsync-tasks). I wish, as you are reporting, that the problem has been fixed.
Hopefully I am not misusing the term, but I referred to ACL (https://en.wikipedia.org/wiki/Access_control_list) as the permission system in use in NTFS and moder Windows OSes. I don't use anything really fancy, but I have personal directories for different users that should not be accessible by other without permissions.
As soon as I have some time, I will try to rsync Windows datasets and see if the permissions are correctly preserved.

Now, the difference for me, I only do a one way sync where I push data from the Main NAS to the Backup NAS because I don't make changes on the Backup system, I only make changes on the Main NAS.
Being that the case, it seems that the replication task would be more appropriate (https://forums.freenas.org/index.php?threads/replicating-data-between-2-freenas-installs.57785/).

Finally, I also found this thread (https://forums.freenas.org/index.php?threads/bidirectional-sync-of-two-freenases.63553/) that suggests another interesting setup. Unfortunately, it requires to create different shares based on how you need to access the data rather than on the logical organisation of the data itself. Also, same problem as above with shares and permissions.
 

Chris Moore

Hall of Famer
Joined
May 2, 2015
Messages
10,080
That's probably the thing that makes the biggest difference for me. I only have one user account because I'm basically the only one that accesses the NAS.

Sent from my SAMSUNG-SGH-I537 using Tapatalk
 
Status
Not open for further replies.
Top