RAID 1 (mirror) only of a part of disks

Status
Not open for further replies.

Kaitux

Dabbler
Joined
Jun 9, 2016
Messages
19
Hello,

I'm new to freenas (9.10 stable) and got a question about mirrorring two disks (sorry if it is a stupid faq question... i havnt found the answer in the forum...) and i'm a bit confused about the whole partition on zfs-disks.

I've got 2x 3TB disks and want to mirror only a part of them.
Specificly i want to
- mirror 2 TB of Data (Data that is only on freenas with read/write access over lan/vpn)
- one partition of 1 TB on disk 1 for a time machine partition for 2 macs
- one partition of 1 TB of Data (several user Data that is syncd to different PCs - so no need to mirror it between my two nas-disks)

Is this set-up possible or is raid1/mirror always a volume, that includes the whole two disks? In Volume Manager is no option to reduce the space of the 2 disks when mirror is picked)
Thanks for help
 

Bidule0hm

Server Electronics Sorcerer
Joined
Aug 5, 2013
Messages
3,710

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
I've got 2x 3TB disks and want to mirror only a part of them.
That is possible, but not through the GUI, and it isn't recommended. In brief, you'd need to partition the disks yourself, create the pools from the CLI, export them, and import them via the GUI. It would look kind of like this, assuming the disks are /dev/da0 and /dev/da1:
  • Partition /dev/da0 so that /dev/da0p1 is 2 TB, and /dev/da0p2 is the remaining 1 TB. Do the same with da1.
  • From the CLI, 'zpool create tank1 mirror /dev/da0p1 /dev/da1p1'
  • 'zpool create tank2 /dev/da0p2'
  • 'zpool create tank3 /dev/da1p2'
  • 'zpool export tank1', tank2, and tank3
  • tank1 is your mirrored volume; tank2 and tank3 are each the remaining 1 TB on those two disks. You can now import them through the GUI
Not a good idea at all, but it should be possible.
 

Kaitux

Dabbler
Joined
Jun 9, 2016
Messages
19
Thanks a lot for your fast help!
In this case i'll mirror the whole two disks, wait until they are full and buy a third disk, which will be stripped normaly.
 

Sakuru

Guru
Joined
Nov 20, 2015
Messages
527

Kaitux

Dabbler
Joined
Jun 9, 2016
Messages
19
Thanks A LOT for your hint and link Sakuru!
I understand now the fact, that whatever vdev in a zpool is failing, destroys the whole zpool.
The further question i've got now is, why would you mix more vdevs in one zpool, when you just can create another zpool instead? What is the advantage of having more vdevs in one zpool? Why not always create another zpool?

In my case:
1st zpool/volume: 2x3TB mirror
2nd zpool/volume: 1x3TB stripped
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
What is the advantage of having more vdevs in one zpool?
In short, because having all of your storage in one volume is very convenient in many circumstances. Also, multiple vdevs improve performance, which is pretty helpful if you're using your pool as a datastore for VMs.
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
Thanks A LOT for your hint and link Sakuru!
I understand now the fact, that whatever vdev in a zpool is failing, destroys the whole zpool.
The further question i've got now is, why would you mix more vdevs in one zpool, when you just can create another zpool instead? What is the advantage of having more vdevs in one zpool? Why not always create another zpool?

In my case:
1st zpool/volume: 2x3TB mirror
2nd zpool/volume: 1x3TB stripped
I think it's more strange when people create multiple pools. It's way more common to have multiple vdevs. It gives you better performance and simple adminstration.
 
Status
Not open for further replies.
Top