Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 643426

Summary: net-fs/samba-4.5.x with sys-cluster/ceph-12.2.2 - default/source3/modules/vfs_ceph_85.o: In function `cephwrap_fstat': vfs_ceph.c:(.text+0x1b88): undefined reference to `ceph_fstat'
Product: Gentoo Linux Reporter: Spooky Ghost <spookyghost>
Component: Current packagesAssignee: Gentoo's SAMBA Team <samba>
Status: RESOLVED FIXED    
Severity: normal CC: j6yNRdsH5Fc3
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: net-fs:samba-4.5.10-r1:20180104-200532.log.xz
use flag to disable buldling cephfs vfs module

Description Spooky Ghost 2018-01-04 16:06:45 UTC
During the rebuild after moving to a 17.0 profile samba failed to build the vfs_ceph module against my current ceph version.  I added https://github.com/samba-team/samba/commit/a9c5be394da4f20bcfea7f6d4f5919d5c0f90219 from the samba git repository as a patch to the the samba 4.5.10-r1 ebuild which resolved the issue.

The samba build error was:

default/source3/modules/vfs_ceph_85.o: In function `cephwrap_fstat':
vfs_ceph.c:(.text+0x1b88): undefined reference to `ceph_fstat'
default/source3/modules/vfs_ceph_85.o: In function `cephwrap_lstat':
vfs_ceph.c:(.text+0x35ed): undefined reference to `ceph_lstat'
default/source3/modules/vfs_ceph_85.o: In function `cephwrap_stat':
vfs_ceph.c:(.text+0x374d): undefined reference to `ceph_stat'
collect2: error: ld returned 1 exit status
Waf: Leaving directory `/var/tmp/portage/net-fs/samba-4.5.10-r1/work/samba-4.5.10-abi_x86_64.amd64/bin'
Build failed:  -> task failed (err #1):
        {task: cc_link posixacl_xattr_2.o,vfs_ceph_85.o -> libvfs_module_ceph.so}

I don't actually use the functionality so cannot confirm if there is a runtime impact.
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2018-01-05 22:27:08 UTC
Created attachment 513486 [details]
net-fs:samba-4.5.10-r1:20180104-200532.log.xz
Comment 2 Dyweni 2018-01-06 16:53:25 UTC
This happens on the 13.0 profile too, Ceph 12.2.2 and Samba 4.5.10
Comment 3 Dyweni 2018-01-12 16:35:12 UTC
Using the 13.0 profile and having Ceph 12.2.2 installed

- samba 4.5.10-r1 fails
- samba 4.5.15 fails
- samba 4.6.11 works (with the ceph use flag off)

I have not tested later versions of samba


My environment is to have the samba available to mount shares and ceph installed to act as an OSD, but to not have samba build support for ceph.
Comment 4 Dyweni 2018-01-12 19:03:48 UTC
Created attachment 514538 [details, diff]
use flag to disable buldling cephfs vfs module

The patch I created for the Samba 4.5.10-r1 ebuild file will add the 'ceph' use flag and if not set, pass the --disable-cephfs flag to the configure program.

With the flag not set, Samba 4.5.10-r1 building correctly for me, on the 13 profile, with Ceph 12.2.2 already installed.

Note that in my case, I have build Samba without CephFS support.  If CephFS support is needed, actual code changes to Samba itself will be required.
Comment 5 Larry the Git Cow gentoo-dev 2018-01-13 12:58:56 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=313e5ad72aa18c4b9453a12b71435e8d6cf74b59

commit 313e5ad72aa18c4b9453a12b71435e8d6cf74b59
Author:     Lars Wendler <polynomial-c@gentoo.org>
AuthorDate: 2018-01-13 12:58:37 +0000
Commit:     Lars Wendler <polynomial-c@gentoo.org>
CommitDate: 2018-01-13 12:58:51 +0000

    net-fs/samba: Disabled ceph support in samba-4.5
    
    Closes: https://bugs.gentoo.org/643426
    Package-Manager: Portage-2.3.19, Repoman-2.3.6

 net-fs/samba/samba-4.5.10-r1.ebuild | 3 ++-
 net-fs/samba/samba-4.5.15.ebuild    | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)