bundles/backup-server: use raidz2 if we have enough devices

This commit is contained in:
Franzi 2025-07-13 18:29:36 +02:00
parent 0c877e5d10
commit 99d373c73b
Signed by: kunsi
GPG key ID: 12E3D2136B818350

View file

@ -97,7 +97,9 @@ def zfs_pool(metadata):
'devices': pool_devices, 'devices': pool_devices,
}] }]
if len(pool_devices) > 2: if len(pool_devices) > 3:
pool_config[0]['type'] = 'raidz2'
elif len(pool_devices) > 2:
pool_config[0]['type'] = 'raidz' pool_config[0]['type'] = 'raidz'
elif len(pool_devices) > 1: elif len(pool_devices) > 1:
pool_config[0]['type'] = 'mirror' pool_config[0]['type'] = 'mirror'