mon [stretch mode]: support disable_stretch_mode
Problem:
Currently, Ceph lacks the ability
to exit stretch mode and move back
to normal cluster (non-stretched).
Solution:
Provide a command to allow
the user to exit stretch mode gracefully:
`ceph mon disable_stretch_mode <crush_rule> --yes-i-really-mean-it`
User can either specify a crush rule that
they want all pools to move to or not specify
a rule and Ceph will use a default replicated crush rule.
Fixes: https://tracker.ceph.com/issues/67467
Signed-off-by: Kamoltat Sirivadhna <ksirivad@redhat.com>
(cherry picked from commit
78ce68de41b1d5278e14cf56dff7f15394969255)
Conflicts:
src/mon/MonmapMonitor.cc - replace `goto reply` with
`goto reply_no_propose`
src/mon/OSDMonitorcc - replace `rule_valid_for_pool_type`
with `get_rule_type` since
`rule_valid_for_pool_type` is not
backported.