1

Background on this question: I have a litte server with five HDDs pooled together in a RAIDZ. Last week one of my HDDs died. So I bought a new HDD and replaced the dead HDD. During the resilvering the inevitable happend - another HDD died but thanks to ZFS I could recover most of my data (Thanks to all my friends for supplying external disks).

Now as I'm replacing the second HDD and need to destroy my old pool I'm thinking about creating a degraded RAIDZ2 with my five HDDs for adding a sixth HDD later. Why could this be a bad idea.

m4rcs
  • 49
  • 3

2 Answers2

2

It is not the same as a RaidZ1 vdev, because the parity is calculated for two spare drives. This causes performance decreases in case one drive is missing and will perform worse than a RaidZ1 vdev.

However, for uncritical data and if you are planning to attach the missing drive in the near future, a procedure similar to this

https://forums.freenas.org/index.php?threads/quick-and-dirty-creating-a-degraded-raidz-3-of-4-drives-i-e-to-allow-migration.7748/

is applicable and currently the only solution to expand a zfs vdev with an additional disk.

Another possible solution is to create a RaidZ1 vdev now and add another vdev to the pool later, like a mirror of two disks.

fmetz
  • 213
  • 1
  • 6
1

You can't create a "degraded RAIDZ2", unless you're talking about created the RAIDZ2 pool with all SIX disks, then removing one. But at this point, why not build the pool the way you need in the first place? It's a bad idea because it's just not good engineering.

Recall that RAIDZ arrays in ZFS cannot be expanded. Your only expandable option is to use RAID mirrors in ZFS or add another group of RAIDZ disks. Mirrors are my recommendation with the types of disks (consumer?) you're probably using.

For further reading, check out: http://nex7.blogspot.com/2013/03/readme1st.html

ewwhite
  • 194,921
  • 91
  • 434
  • 799
  • 1
    Year I know that I can't create it directly but there are some ways of using a file as a sixth disk [like here](http://jeanbruenn.info/2011/01/18/setting-up-zfs-with-3-out-of-4-discs-raidz/). Another problem is that my current server has no free slots for the sixth disk - but I will upgrade the server later this year. – m4rcs Aug 04 '14 at 10:14
  • @m4rcs One of the main rules of ZFS is to use equal-sized and equally-capable disks. What you're speaking of is pretty *janky*. Since you asked "why could this be a bad idea", the answer is because it would perform poorly, be unstable, is a little dangerous and you run the risk of data loss when you attempt to transition to your new system. – ewwhite Aug 04 '14 at 13:53