New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mon,crush: create crush rules using device classes for replicated and ec pools via cli #16027

Merged
merged 7 commits into from Jul 9, 2017

Conversation

Projects
None yet
3 participants
@liewegas
Member

liewegas commented Jun 29, 2017

for replicated pools:

ceph osd crush rule create-replicated [class]

for ec pools:

ceph osd erasure-code-profile set ec-foo-ssd crush-device-class=ssd m=2 k=2
ceph osd pool create ec-foo 8 erasure ec-foo-ssd

also some cleanup in the ec profiles, mainly renaming ruleset-* properties to crush-* properties.

@liewegas liewegas requested a review from jecluis Jun 30, 2017

@liewegas liewegas changed the title from mon,crush: 'osd crush rule create-replicated ...' to mon,crush: create crush rules using device classes for replicated and ec pools via cli Jun 30, 2017

@gregsfortytwo

This comment has been minimized.

Member

gregsfortytwo commented Jun 30, 2017

That's a real build failure, @liewegas.

@ghost ghost requested a review from Jul 5, 2017

@ghost

ghost approved these changes Jul 5, 2017

@ghost

This comment has been minimized.

ghost commented Jul 5, 2017

Just had cosmetic comments, LGTM otherwise once the test failures are fixed. The duplication in ErasureCode that you factorized was intentional: I thought they would diverge for various reasons and that it would be better to change each implementation without trying to generalize. However, years after that, they stayed the same so I was wrong and the refactor is good :-)

@liewegas

This comment has been minimized.

Member

liewegas commented Jul 5, 2017

retest this please

liewegas added some commits Jun 29, 2017

mon,crush: 'osd crush rule create-replicated ...'
New command to create crush rule that specifies a class of device.  Plus
all of the fallout in other callers to the CrushWrapper helpers, the
crushtool cli change, and cli test.

Signed-off-by: Sage Weil <sage@redhat.com>
erasure-code: ruleset-* -> crush-*
1) ruleset is an obsolete term, and
2) crush-{rule,failure-domain,...} is more descriptive.

Note that we are changing the names of the erasure code profile keys
from ruleset-* to crush-*.  We will update this on upgrade when the
luminous flag is set, but that means that during mon upgrade you cannot
create EC pools that use these fields.

When the upgrade completes (users sets require_osd_release = luminous)
existing ec profiles are updated automatically.

Signed-off-by: Sage Weil <sage@redhat.com>
erasure-code: factor generic create_rule into parent ErasureCode
These 3 implementations are all identical.  Move the rest of init() to
into the parent since these all behave the same.

Signed-off-by: Sage Weil <sage@redhat.com>
erasure-code: implement 'crush-device-class' ec profile property
Signed-off-by: Sage Weil <sage@redhat.com>
erasure-code/lrc: implement crush-device-class property
Signed-off-by: Sage Weil <sage@redhat.com>
qa/workunits/mon/crush_ops.sh: require luminous before using device c…
…lasses

Signed-off-by: Sage Weil <sage@redhat.com>

@liewegas liewegas modified the milestone: luminous Jul 6, 2017

@liewegas

This comment has been minimized.

Member

liewegas commented Jul 7, 2017

retest this please

@liewegas

This comment has been minimized.

Member

liewegas commented Jul 7, 2017

need to fix cli test before merge

test/cli/crushtool: fix rules.t
Signed-off-by: Sage Weil <sage@redhat.com>

@liewegas liewegas merged commit 8b21c6b into ceph:master Jul 9, 2017

3 of 4 checks passed

make check make check failed
Details
Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
make check (arm64) make check succeeded
Details

@liewegas liewegas deleted the liewegas:wip-crush-rule-class branch Jul 9, 2017

@tchaikov

This comment has been minimized.

Contributor

tchaikov commented Jul 9, 2017

@liewegas can we close http://tracker.ceph.com/issues/20446 now? since this PR has been merged.

@liewegas

This comment has been minimized.

Member

liewegas commented Jul 9, 2017

xiexingguo added a commit to xiexingguo/ceph that referenced this pull request Jul 10, 2017

test: fix ut and release-notes
To keep pace with the newly merged ceph#16027

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>

dmick added a commit to dmick/ceph that referenced this pull request Jul 18, 2017

test: fix ut and release-notes
To keep pace with the newly merged ceph#16027

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment