Commit 72d55ee
osd: Optimized EC calculate_maxles_and_minlua needs to use ...
exclude_nonprimary_shards
When an optimized EC pool is searching for the best shard that
isn't a non-primary shard then the calculation for maxles and
minlua needs to exclude nonprimary-shards
This bug was seen in a test run where activating a PG was
interrupted by a new epoch and only a couple of non-primary
shards became active and updated les. In the next epoch
a new primary (without log) failed to find a shard that
wasn't non-primary with the latest les. The les of
non-primary shards should be ignored when looking for
an appropriate shard to get the full log from.
This is safe because an epoch cannot start I/O without
at least K shards that have updated les, and there
are always K-1 non-primary shards. If I/O has started
then we will find the latest les even if we skip
non-primary shards. If I/O has not started then the
latest les ignoring non-primary shards is the
last epoch in which I/O was started and has a good
enough log+missing list.
Signed-off-by: Bill Scales <[email protected]>1 parent 3c2161e commit 72d55ee
2 files changed
+6
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1615 | 1615 | | |
1616 | 1616 | | |
1617 | 1617 | | |
| 1618 | + | |
1618 | 1619 | | |
1619 | 1620 | | |
1620 | 1621 | | |
1621 | 1622 | | |
1622 | 1623 | | |
1623 | 1624 | | |
1624 | 1625 | | |
| 1626 | + | |
| 1627 | + | |
| 1628 | + | |
1625 | 1629 | | |
1626 | 1630 | | |
1627 | 1631 | | |
| |||
1665 | 1669 | | |
1666 | 1670 | | |
1667 | 1671 | | |
| 1672 | + | |
1668 | 1673 | | |
1669 | 1674 | | |
1670 | 1675 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1691 | 1691 | | |
1692 | 1692 | | |
1693 | 1693 | | |
| 1694 | + | |
1694 | 1695 | | |
1695 | 1696 | | |
1696 | 1697 | | |
| |||
0 commit comments