Skip to content

Commit 3276471

Browse files
committed
mgr/cephadm: make enable_monitor_client configurable for nvmeof
Currently, the mon client work is not merged on main, but our default nvmeof container will attempt to make use of it by default, causing it to crash. This makes it configurable and defaults the behavior to false. That can be changed once the work is actually present in main. Signed-off-by: Adam King <[email protected]>
1 parent c2bb1a2 commit 3276471

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

src/pybind/mgr/cephadm/templates/services/nvmeof/ceph-nvmeof.conf.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ omap_file_update_reloads = {{ spec.omap_file_update_reloads }}
1919
allowed_consecutive_spdk_ping_failures = {{ spec.allowed_consecutive_spdk_ping_failures }}
2020
spdk_ping_interval_in_seconds = {{ spec.spdk_ping_interval_in_seconds }}
2121
ping_spdk_under_lock = {{ spec.ping_spdk_under_lock }}
22+
enable_monitor_client = {{ spec.enable_monitor_client }}
2223

2324
[gateway-logs]
2425
log_level = {{ spec.log_level }}

src/pybind/mgr/cephadm/tests/test_services.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -404,6 +404,7 @@ def test_nvmeof_config(self, _get_name, _run_cephadm, cephadm_module: CephadmOrc
404404
allowed_consecutive_spdk_ping_failures = 1
405405
spdk_ping_interval_in_seconds = 2.0
406406
ping_spdk_under_lock = False
407+
enable_monitor_client = False
407408
408409
[gateway-logs]
409410
log_level = INFO

src/python-common/ceph/deployment/service_spec.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1352,6 +1352,7 @@ def __init__(self,
13521352
max_log_directory_backups: Optional[int] = 10,
13531353
log_directory: Optional[str] = '/var/log/ceph/',
13541354
monitor_timeout: Optional[float] = 1.0,
1355+
enable_monitor_client: bool = False,
13551356
placement: Optional[PlacementSpec] = None,
13561357
unmanaged: bool = False,
13571358
preview_only: bool = False,
@@ -1454,6 +1455,8 @@ def __init__(self,
14541455
self.log_directory = log_directory or '/var/log/ceph/'
14551456
#: ``monitor_timeout`` monitor connectivity timeout
14561457
self.monitor_timeout = monitor_timeout
1458+
#: ``enable_monitor_client`` whether to connect to the ceph monitor or not
1459+
self.enable_monitor_client = enable_monitor_client
14571460

14581461
def get_port_start(self) -> List[int]:
14591462
return [5500, 4420, 8009]

0 commit comments

Comments
 (0)