Separate slices and pool for System Dataset?

Status
Not open for further replies.

nelem

Dabbler
Joined
Sep 28, 2017
Messages
10
I have a primary NAS with 4x6TB in RAIDZ2 and just got a second for backup with the same configuration. On both machines, the system dataset is on the main pool. When starting the replication, FreeNAS objected to the system dataset being on the replication target pool. This seemed to make sense as it would be overwritten, so I moved the dataset to the freenas-boot pool which is a USB stick and therefore sub-optimal to hold the system dataset.

I am considering adding a 2GB (or whatever) slice on each drive and creating an additional pool across these to hold the system dataset.

Will this work? Is it sensible? Is it worth the hassle? If it was sensible, I would assume the FreeNAS installer would offer to create a small pool for the dataset if all storage was going to be allocated to a single pool.
 

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
so I moved the dataset to the freenas-boot pool which is a USB stick
No!

I am considering adding a 2GB (or whatever) slice on each drive and creating an additional pool across these to hold the system dataset.
No!

Is it sensible?
No! This goes against everything ZFS is about. You're looking at the problem in the completely wrong way.
Your problem is that you're doing things in the top-level dataset - don't! If you have data there, move it to child datasets. If you're just trying to recursively replicate the whole pool, don't - instead, replicate individual datasets. If this seems wrong to you, make them children of a single dataset which you can then recursively replicate.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
When starting the replication, FreeNAS objected to the system dataset being on the replication target pool.
Put the replicated data into a dataset, and you won't have this problem.
 

nelem

Dabbler
Joined
Sep 28, 2017
Messages
10
No!
No! This goes against everything ZFS is about. You're looking at the problem in the completely wrong way.
Your problem is that you're doing things in the top-level dataset - don't! If you have data there, move it to child datasets. If you're just trying to recursively replicate the whole pool, don't - instead, replicate individual datasets. If this seems wrong to you, make them children of a single dataset which you can then recursively replicate.
Thanks, @Ericloewe and @danb35, I get it. Make sure the top-level dataset only contains datasets that can be replicated. The top-level dataset does actually contain mostly, but not exclusively, datasets which I was 'forced' to use for Windows shares.

Is there a simple method to convert directories to datasets? Also, how to tell from the command iine which is a dataset and which is a simple directory?

Is there any limit to the nesting depth of child datasets? Just wondering really.
 

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
Is there a simple method to convert directories to datasets?
No, you'll have to rename the directory, make the dataset and move stuff over. But stuff should mostly just work from there on.

Also, how to tell from the command iine which is a dataset and which is a simple directory?
Datasets are listed by zfs list -r poolname.

Is there any limit to the nesting depth of child datasets? Just wondering really.
Pretty sure there isn't one. I think there is a limit to the maximum number of datasets, but it's astronomically high.
 

nelem

Dabbler
Joined
Sep 28, 2017
Messages
10
Thanks. All sweet now. A small chore to setup the snaphosts and replications but now have the addtional benefit of different snapshot schedeules for different datasets.
 

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
now have the addtional benefit of different snapshot schedeules for different datasets.
Now you are beginning to understand the power of the force ZFS. Let it guide you, and you will be at peace.
 
Status
Not open for further replies.
Top