From 49294965f9f92946382949264344c2aa0b6d70bd Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Wed, 4 Oct 2017 08:25:38 -0500 Subject: [PATCH] mgr/localpool: fix rule selection The 'osd pool create' arg parsing is broken; the rule name for 'ceph osd pool create $name $numpgs replicated $rulename' is passed via the erasure_code_profile param. Too many req=false options without a way to disambiguate them. Work around it by passing both 'rule' and 'erasure_code_profile' keys, so that if/when the hack in OSDMonitor.cc is removed it will still work. Blech. Signed-off-by: Sage Weil (cherry picked from commit 7623513935525498640defa2064c291fd69a2b76) --- src/pybind/mgr/localpool/module.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/pybind/mgr/localpool/module.py b/src/pybind/mgr/localpool/module.py index fac3d1c7f6c71..0abdbfbc741ae 100644 --- a/src/pybind/mgr/localpool/module.py +++ b/src/pybind/mgr/localpool/module.py @@ -54,6 +54,7 @@ class Module(MgrModule): "format": "json", "pool": pool_name, 'rule': pool_name, + 'erasure_code_profile': pool_name, "pool_type": 'replicated', 'pg_num': str(pg_num), }), "") -- 2.39.5