I want to create a zfs raidz2 with 4 disks. I know this will "waste" at least 50% of the space but I aim at a high tolerance against disk failures. Using 5 disks for raidz2 is not recommended and 6 disks is to expensive and unnecessary for me. I will have 3 TB (or maybe 4 TB) disks which all have 4k sectors with 512 byte emulation.
I have read many things about zfs and raidz2 and I am starting to get confused.
Should I partition the disks? I read that it is a good idea to create partitions in order to make the OS aware that the disk is not empty. The partitioning can also help to align to 4k sectors.
GPT or MBR? As far as I understood GPT is a must for 3 TB disks (and larger).
How should I create the partition? Will this give me a correctly aligned partitions?
sudo parted --align optimal /dev/sdX
mklabel gpt
mkpart primary 1 0% 3TB
Bonus question: how big will the partition created by mkpart primary 1 0% 3TB be? Will it be 3*10^12 - 4096 byte?
My intention is to not use the full size of the disk but to limit myself to 3 TB in order to be able to replace a failed drive with a different model.
Do I need ashift=12 if I have aligned partitions? Is it useless? Does it harm me somehow?
What about the stripsize? Do I need to modify it? What if I use 5 disks instead of 4 disks?
Is there anything else what I should consider?