The Samba-Bugzilla – Attachment 14334 Details for
Bug 13506
vfs_ceph lies about flock support
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
fix for 4.7.next
bso13506_vfs_ceph_lies_about_flock_47t.patchset (text/plain), 3.81 KB, created by
David Disseldorp
on 2018-07-24 14:24:12 UTC
(
hide
)
Description:
fix for 4.7.next
Filename:
MIME Type:
Creator:
David Disseldorp
Created:
2018-07-24 14:24:12 UTC
Size:
3.81 KB
patch
obsolete
>From d28ff2d9d3bf87b5b0a9f99a7e33499487955e98 Mon Sep 17 00:00:00 2001 >From: David Disseldorp <ddiss@samba.org> >Date: Thu, 5 Jul 2018 17:18:15 +0200 >Subject: [PATCH 1/2] vfs_ceph: don't lie about flock support > >Instead, match vfs_gluster behaviour and require that users explicitly >disable "kernel share modes". > >Bug: https://bugzilla.samba.org/show_bug.cgi?id=13506 > >Signed-off-by: David Disseldorp <ddiss@samba.org> >Reviewed-by: Jeremy Allison <jra@samba.org> >(cherry picked from commit 926ae50627d536735cee9b3931ee35bc19060261) >--- > docs-xml/manpages/vfs_ceph.8.xml | 8 ++++++++ > source3/modules/vfs_ceph.c | 11 +++++------ > 2 files changed, 13 insertions(+), 6 deletions(-) > >diff --git a/docs-xml/manpages/vfs_ceph.8.xml b/docs-xml/manpages/vfs_ceph.8.xml >index c492d31979d..757b20ff489 100644 >--- a/docs-xml/manpages/vfs_ceph.8.xml >+++ b/docs-xml/manpages/vfs_ceph.8.xml >@@ -62,7 +62,15 @@ > <programlisting> > <smbconfsection name="[share]"/> > <smbconfoption name="vfs objects">ceph</smbconfoption> >+ <smbconfoption name="path">/non-mounted/cephfs/path</smbconfoption> >+ <smbconfoption name="kernel share modes">no</smbconfoption> > </programlisting> >+ >+ <para> >+ Note that currently <command>kernel share modes</command> have >+ to be disabled in a share running with the CephFS vfs module for >+ file serving to work properly. >+ </para> > </refsect1> > > <refsect1> >diff --git a/source3/modules/vfs_ceph.c b/source3/modules/vfs_ceph.c >index 9f752837a6a..57bafec098c 100644 >--- a/source3/modules/vfs_ceph.c >+++ b/source3/modules/vfs_ceph.c >@@ -1261,12 +1261,11 @@ static bool cephwrap_lock(struct vfs_handle_struct *handle, files_struct *fsp, i > static int cephwrap_kernel_flock(struct vfs_handle_struct *handle, files_struct *fsp, > uint32_t share_mode, uint32_t access_mask) > { >- DBG_DEBUG("[CEPH] kernel_flock\n"); >- /* >- * We must return zero here and pretend all is good. >- * One day we might have this in CEPH. >- */ >- return 0; >+ DBG_ERR("[CEPH] flock unsupported! Consider setting " >+ "\"kernel share modes = no\"\n"); >+ >+ errno = ENOSYS; >+ return -1; > } > > static bool cephwrap_getlock(struct vfs_handle_struct *handle, files_struct *fsp, off_t *poffset, off_t *pcount, int *ptype, pid_t *ppid) >-- >2.13.7 > > >From ceaf6f89cdf337e3e9a509c4f4f95e10b1a36768 Mon Sep 17 00:00:00 2001 >From: David Disseldorp <ddiss@samba.org> >Date: Fri, 6 Jul 2018 13:31:43 +0200 >Subject: [PATCH 2/2] docs/vfs_ceph: add CTDB_SAMBA_SKIP_SHARE_CHECK=yes caveat > >Mostly copied from the vfs_gluster manpage: the CephFS share path is not >locally mounted, which breaks the ctdb_check_directories_probe() check. > >Signed-off-by: David Disseldorp <ddiss@samba.org> >Reviewed-by: Jeremy Allison <jra@samba.org> > >Autobuild-User(master): Jeremy Allison <jra@samba.org> >Autobuild-Date(master): Fri Jul 6 23:19:02 CEST 2018 on sn-devel-144 > >(cherry picked from commit 0cd44821f3889067620d685344c3eaf913a31329) >--- > docs-xml/manpages/vfs_ceph.8.xml | 11 +++++++++++ > 1 file changed, 11 insertions(+) > >diff --git a/docs-xml/manpages/vfs_ceph.8.xml b/docs-xml/manpages/vfs_ceph.8.xml >index 757b20ff489..c6de28a8144 100644 >--- a/docs-xml/manpages/vfs_ceph.8.xml >+++ b/docs-xml/manpages/vfs_ceph.8.xml >@@ -67,6 +67,17 @@ > </programlisting> > > <para> >+ Since <command>vfs_ceph</command> does not require a filesystem >+ mount, the share <command>path</command> is treated differently: >+ it is interpreted as an absolute path within the Ceph filesystem >+ on the attached Ceph cluster. >+ In a ctdb cluster environment where ctdb manages Samba, >+ <command>CTDB_SAMBA_SKIP_SHARE_CHECK=yes</command> must be >+ configured to disable local share path checks, otherwise ctdb >+ will not reach a healthy state. >+ </para> >+ >+ <para> > Note that currently <command>kernel share modes</command> have > to be disabled in a share running with the CephFS vfs module for > file serving to work properly. >-- >2.13.7 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Flags:
jra
:
review+
Actions:
View
Attachments on
bug 13506
: 14334 |
14335