]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mon: pool set <pool> crush_ruleset must not use rule_exists 1962/head
authorJohn Spray <john.spray@inktank.com>
Tue, 20 May 2014 15:50:18 +0000 (16:50 +0100)
committerLoic Dachary <loic@dachary.org>
Sat, 14 Jun 2014 10:56:59 +0000 (12:56 +0200)
commitd02d46e25080d5f7bb8ddd4874d9019a078b816b
treed32fbd1284dbb219b7d9b27192f4ff249540bf3d
parent572241942706e2f845a147f19717bf6c487f23f4
mon: pool set <pool> crush_ruleset must not use rule_exists

Implement CrushWrapper::ruleset_exists that iterates over the existing
rulesets to find the one matching the ruleset argument.

ceph osd pool set <pool> crush_ruleset must not use
CrushWrapper::rule_exists, which checks for a *rule* existing, whereas
the value being set is a *ruleset*. (cherry picked from commit
fb504baed98d57dca8ec141bcc3fd021f99d82b0)

A test via ceph osd pool set data crush_ruleset verifies the ruleset
argument is accepted.

http://tracker.ceph.com/issues/8599 fixes: #8599

Backport: firefly, emperor, dumpling
Signed-off-by: John Spray <john.spray@inktank.com>
Signed-off-by: Loic Dachary <loic@dachary.org>
qa/workunits/cephtool/test.sh
src/crush/CrushWrapper.h
src/mon/OSDMonitor.cc