From: John Mulligan Date: Wed, 25 Feb 2026 00:22:03 +0000 (-0500) Subject: mgr/smb: add new log_level parameter to cluster resource spec X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=5d51d4c110a1763bbb7cbfa5be94523d6fc96a06;p=ceph.git mgr/smb: add new log_level parameter to cluster resource spec Allow specifying various log levels via a new log_level dict. Currently the logging targets are "smb" and "ctdb". The "smb" level will affect samba services (smbd, winbindd, etc.) the "ctdb" level will affect ctdbd. Signed-off-by: John Mulligan --- diff --git a/src/pybind/mgr/smb/resources.py b/src/pybind/mgr/smb/resources.py index 20064c5e5f4..29ca657b4b6 100644 --- a/src/pybind/mgr/smb/resources.py +++ b/src/pybind/mgr/smb/resources.py @@ -647,6 +647,9 @@ class Cluster(_RBase): # connect the smb cluster and all its shares to cephfs file systems # hosted on an external ceph cluster external_ceph_cluster: Optional[ExternalCephClusterSource] = None + # debug_level can be used to change the smb services + # default debugging levels + debug_level: Optional[dict[str, str]] = None def validate(self) -> None: if not self.cluster_id: @@ -678,11 +681,13 @@ class Cluster(_RBase): raise ValueError( 'bind_addrs must have at least one value or not be set' ) + validation.check_debug_level(self.debug_level) @resourcelib.customize def _customize_resource(rc: resourcelib.Resource) -> resourcelib.Resource: rc.on_condition(_present) rc.on_construction_error(InvalidResourceError.wrap) + rc.debug_level.quiet = True return rc @property