On Wed, 4 May 2011, Zenon Panoussis wrote:
> I thought that min_size in crush is obvious, but the more I read the more
> I tend to doubt. So I might as well ask:
>
> With a crushmap like this
>
> ===
> type 0 device
> type 1 host
> type 2 root
>
> [definitions for the above; hosts contain devices, root contains hosts]
>
> rule data {
> ruleset 0
> type replicated
> min_size 2
> max_size 2
> step take root
> step chooseleaf firstn 0 type host
> step emit
> }
> ===
>
> does "min_size 2, max_size 2" mean that I want "2 copies of the data on each
> host" or "2 copies of the data in total in the entire cluster"?
Neither, actually. It means that this rule will be used when we ask crush
for ruleset 0 and 2 replicas. If you change a pg to have 3x replication,
ceph will ask for ruleset 0 and 3 replicas, and this rule won't be used.
You probably want min_size 1 and max_size 10.
The motivation is that you might have different placement rules depending
on how many replicas there are. That's why it's "ruleset 0" and not
"rule 0".
sage
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html