I have two chassis with 4 nodes each. Each node will have 4 OSDs. I'm trying to write the Crush rule to ensure that all three copies don't end up in the same chassis. I modified the existing rule as below, but half the PGs went "unknown" until I put it back. I fear I just don't understand choose vs chooseleaf.
Before change:
After change:
Before change:
Code:
rule replicated_nvme {
id 2
type replicated
min_size 1
max_size 10
step take default class nvme
step chooseleaf firstn 0 type host
step emit
}
After change:
Code:
rule replicated_nvme {
id 2
type replicated
min_size 1
max_size 10
step take default class nvme
step choose firstn 2 type chassis
step chooseleaf firstn 0 type host
step emit
}