]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/smb: Disable posix locking in share definition 65999/head
authorAnoop C S <anoopcs@cryptolab.net>
Tue, 21 Oct 2025 08:53:50 +0000 (14:23 +0530)
committerAnoop C S <anoopcs@cryptolab.net>
Fri, 14 Nov 2025 08:20:06 +0000 (13:50 +0530)
The prerequisites for supporting durable handles[1] in Samba include
disabling the mapping of POSIX locks, as well as setting the `kernel
oplocks` and `kernel sharemodes` parameters to disabled. Currently
this configuration is hard‑coded, but in the future it could be made
conditional and combined with other settings to enable persistent
handles on continuously available shares.

[1] https://www.samba.org/samba/docs/current/man-html/smb.conf.5.html#DURABLEHANDLES

Signed-off-by: Anoop C S <anoopcs@cryptolab.net>
qa/suites/orch/cephadm/smb/tasks/deploy_smb_basic.yaml
qa/suites/orch/cephadm/smb/tasks/deploy_smb_domain.yaml
src/pybind/mgr/smb/handler.py

index aed5723e9c0e25efa10fc71cde8f5550c0eb58e4..177acd0eb809356203cec059530121c90e79e512 100644 (file)
@@ -60,6 +60,7 @@ tasks:
             "disable spoolss" = "yes"
             "guest ok" = "no"
             "smbd profiling level" = "on"
+            "posix locking" = "no"
             [globals.domain.options]
             security = "USER"
             workgroup = "STANDALONE1"
index 82a21253f7b4d4d7232eb4b1bf80f0e620a12dc2..c6945b5039b15846c55e3d496b4dde3432781779 100644 (file)
@@ -59,6 +59,7 @@ tasks:
           "disable spoolss" = "yes"
           "guest ok" = "no"
           "smbd profiling level" = "on"
+          "posix locking" = "no"
           [globals.domain.options]
           security = "ads"
           workgroup = "DOMAIN1"
index 8e7fe3c76f200017e3a7b617878a9872896971c0..f806f1ffcef9e734aa6fd2bcfcc39f824360c50a 100644 (file)
@@ -721,6 +721,7 @@ def _generate_share(
             'kernel share modes': 'no',
             'x:ceph:id': f'{share.cluster_id}.{share.share_id}',
             'smbd profiling share': 'yes',
+            'posix locking': 'no',
         }
     }
     if share.comment is not None: