Bug 194548 - net/samba41: Samba 4.1.13 errors out with error probing vfs module 'aio_pthread': NT _STATUS_UNSUCCESSFUL
Summary: net/samba41: Samba 4.1.13 errors out with error probing vfs module 'aio_pthre...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: Timur I. Bakeyev
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-23 09:03 UTC by joh.hendriks
Modified: 2014-11-04 02:04 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description joh.hendriks 2014-10-23 09:03:58 UTC
After updating samba to 4.1.13 Samba fails to serve the SMB data.

Samba is build with aio support and pthread support, this is on 10-STABLE from 22-10-2014

When a client connects to the share the following is showing in the log file.

[2014/10/23 09:58:29.997055,  0, pid=73417, effective(0, 0), real(0, 0)] ../lib/util/modules.c:48(load_module)
Oct 23 09:58:29 beasty smbd[73417]:   Error loading module '/usr/local/lib/shared-modules/vfs/aio_pthread.so': Cannot open "/usr/local/lib/shared-modules/vfs/aio_pthread.so"
Oct 23 09:58:29 beasty smbd[73417]: [2014/10/23 09:58:29.997130,  0, pid=73417, effective(0, 0), real(0, 0), class=vfs] ../source3/smbd/vfs.c:184(vfs_init_custom)
Oct 23 09:58:29 beasty smbd[73417]:   error probing vfs module 'aio_pthread': NT_STATUS_UNSUCCESSFUL
Oct 23 09:58:29 beasty smbd[73417]: [2014/10/23 09:58:29.997165,  0, pid=73417, effective(0, 0), real(0, 0), class=vfs] ../source3/smbd/vfs.c:349(smbd_vfs_init)
Oct 23 09:58:29 beasty smbd[73417]:   smbd_vfs_init: vfs_init_custom failed for aio_pthread
Oct 23 09:58:29 beasty smbd[73417]: [2014/10/23 09:58:29.997196,  0, pid=73417, effective(0, 0), real(0, 0)] ../source3/smbd/service.c:640(make_connection_snum)
Oct 23 09:58:29 beasty smbd[73417]:   vfs_init failed for service data
Oct 23 09:58:29 beasty smbd[73417]: [2014/10/23 09:58:29.998696,  0, pid=73417, effective(0, 0), real(0, 0)] ../lib/util/modules.c:48(load_module)
Oct 23 09:58:29 beasty smbd[73417]:   Error loading module '/usr/local/lib/shared-modules/vfs/aio_pthread.so': Cannot open "/usr/local/lib/shared-modules/vfs/aio_pthread.so"
Oct 23 09:58:29 beasty smbd[73417]: [2014/10/23 09:58:29.999004,  0, pid=73417, effective(0, 0), real(0, 0), class=vfs] ../source3/smbd/vfs.c:184(vfs_init_custom)
Oct 23 09:58:29 beasty smbd[73417]:   error probing vfs module 'aio_pthread': NT_STATUS_UNSUCCESSFUL
Oct 23 09:58:29 beasty smbd[73417]: [2014/10/23 09:58:29.999180,  0, pid=73417, effective(0, 0), real(0, 0), class=vfs] ../source3/smbd/vfs.c:349(smbd_vfs_init)
Oct 23 09:58:29 beasty smbd[73417]:   smbd_vfs_init: vfs_init_custom failed for aio_pthread
Oct 23 09:58:29 beasty smbd[73417]: [2014/10/23 09:58:29.999350,  0, pid=73417, effective(0, 0), real(0, 0)] ../source3/smbd/service.c:640(make_connection_snum)
Oct 23 09:58:29 beasty smbd[73417]:   vfs_init failed for service data

When I install samba i see this coming along

* installing bin/default/source3/modules/libvfs-aio-pthread.so as /usr/ports/net/samba41/work/stage/usr/local/lib/shared-modules/vfs/aio_pthread.so

So it looks like it gets installed.
But in the directory the file is not there.

beasty samba41 # ls -al /usr/local/lib/shared-modules/vfs
total 1948
drwxr-xr-x   2 root  wheel    1024 Oct 23 10:33 .
drwxr-xr-x  14 root  wheel     512 Oct 23 10:33 ..
-rwxr-xr-x   1 root  wheel   81344 Oct 23 10:33 acl_tdb.so
-rwxr-xr-x   1 root  wheel   75090 Oct 23 10:32 acl_xattr.so
-rwxr-xr-x   1 root  wheel   72540 Oct 23 10:32 aio_fork.so
-rwxr-xr-x   1 root  wheel   39655 Oct 23 10:33 audit.so
-rwxr-xr-x   1 root  wheel   54428 Oct 23 10:32 cap.so
-rwxr-xr-x   1 root  wheel   59734 Oct 23 10:33 catia.so
-rwxr-xr-x   1 root  wheel   42010 Oct 23 10:33 commit.so
-rwxr-xr-x   1 root  wheel   34574 Oct 23 10:33 crossrename.so
-rwxr-xr-x   1 root  wheel   31993 Oct 23 10:33 default_quota.so
-rwxr-xr-x   1 root  wheel   43715 Oct 23 10:32 dirsort.so
-rwxr-xr-x   1 root  wheel   51376 Oct 23 10:33 expand_msdfs.so
-rwxr-xr-x   1 root  wheel   46851 Oct 23 10:33 extd_audit.so
-rwxr-xr-x   1 root  wheel   31518 Oct 23 10:33 fake_perms.so
-rwxr-xr-x   1 root  wheel  120456 Oct 23 10:33 full_audit.so
-rwxr-xr-x   1 root  wheel   34849 Oct 23 10:33 linux_xfs_sgid.so
-rwxr-xr-x   1 root  wheel  105765 Oct 23 10:33 media_harmony.so
-rwxr-xr-x   1 root  wheel   45563 Oct 23 10:32 netatalk.so
-rwxr-xr-x   1 root  wheel   48444 Oct 23 10:33 posix_eadb.so
-rwxr-xr-x   1 root  wheel   45542 Oct 23 10:33 preopen.so
-rwxr-xr-x   1 root  wheel   34632 Oct 23 10:33 readahead.so
-rwxr-xr-x   1 root  wheel   60340 Oct 23 10:33 readonly.so
-rwxr-xr-x   1 root  wheel   60392 Oct 23 10:33 recycle.so
-rwxr-xr-x   1 root  wheel   68522 Oct 23 10:33 scannedonly.so
-rwxr-xr-x   1 root  wheel   41204 Oct 23 10:33 shadow_copy.so
-rwxr-xr-x   1 root  wheel   96964 Oct 23 10:33 shadow_copy2.so
-rwxr-xr-x   1 root  wheel   80572 Oct 23 10:33 smb_traffic_analyzer.so
-rwxr-xr-x   1 root  wheel   58654 Oct 23 10:32 streams_depot.so
-rwxr-xr-x   1 root  wheel   62385 Oct 23 10:32 streams_xattr.so
-rwxr-xr-x   1 root  wheel   42729 Oct 23 10:32 syncops.so
-rwxr-xr-x   1 root  wheel  106961 Oct 23 10:32 time_audit.so
-rwxr-xr-x   1 root  wheel   49969 Oct 23 10:33 xattr_tdb.so
-rwxr-xr-x   1 root  wheel   92441 Oct 23 10:32 zfsacl.so
beasty samba41 # 

looking in the work folder the file is there.

beasty samba41 # ls -al /usr/ports/net/samba41/work/stage/usr/local/lib/shared-modules/vfs
total 2076
drwxr-xr-x   2 root  wheel    1024 Oct 23 10:33 .
drwxr-xr-x  14 root  wheel     512 Oct 23 10:33 ..
-rwxr-xr-x   1 root  wheel   81344 Oct 23 10:33 acl_tdb.so
-rwxr-xr-x   1 root  wheel   75090 Oct 23 10:32 acl_xattr.so
-rwxr-xr-x   1 root  wheel   72540 Oct 23 10:32 aio_fork.so
-rwxr-xr-x   1 root  wheel   50523 Oct 23 10:33 aio_posix.so
-rwxr-xr-x   1 root  wheel   36626 Oct 23 10:32 aio_pthread.so
-rwxr-xr-x   1 root  wheel   39655 Oct 23 10:33 audit.so
-rwxr-xr-x   1 root  wheel   54428 Oct 23 10:32 cap.so
-rwxr-xr-x   1 root  wheel   59734 Oct 23 10:33 catia.so
-rwxr-xr-x   1 root  wheel   42010 Oct 23 10:33 commit.so
-rwxr-xr-x   1 root  wheel   34574 Oct 23 10:33 crossrename.so
-rwxr-xr-x   1 root  wheel   31993 Oct 23 10:33 default_quota.so
-rwxr-xr-x   1 root  wheel   43715 Oct 23 10:32 dirsort.so
-rwxr-xr-x   1 root  wheel   51376 Oct 23 10:33 expand_msdfs.so
-rwxr-xr-x   1 root  wheel   46851 Oct 23 10:33 extd_audit.so
-rwxr-xr-x   1 root  wheel   31518 Oct 23 10:33 fake_perms.so
-rwxr-xr-x   1 root  wheel  120456 Oct 23 10:33 full_audit.so
-rwxr-xr-x   1 root  wheel   34849 Oct 23 10:33 linux_xfs_sgid.so
-rwxr-xr-x   1 root  wheel  105765 Oct 23 10:33 media_harmony.so
-rwxr-xr-x   1 root  wheel   45563 Oct 23 10:32 netatalk.so
-rwxr-xr-x   1 root  wheel   40779 Oct 23 10:33 notify_fam.so
-rwxr-xr-x   1 root  wheel   48444 Oct 23 10:33 posix_eadb.so
-rwxr-xr-x   1 root  wheel   45542 Oct 23 10:33 preopen.so
-rwxr-xr-x   1 root  wheel   34632 Oct 23 10:33 readahead.so
-rwxr-xr-x   1 root  wheel   60340 Oct 23 10:33 readonly.so
-rwxr-xr-x   1 root  wheel   60392 Oct 23 10:33 recycle.so
-rwxr-xr-x   1 root  wheel   68522 Oct 23 10:33 scannedonly.so
-rwxr-xr-x   1 root  wheel   41204 Oct 23 10:33 shadow_copy.so
-rwxr-xr-x   1 root  wheel   96964 Oct 23 10:33 shadow_copy2.so
-rwxr-xr-x   1 root  wheel   80572 Oct 23 10:33 smb_traffic_analyzer.so
-rwxr-xr-x   1 root  wheel   58654 Oct 23 10:32 streams_depot.so
-rwxr-xr-x   1 root  wheel   62385 Oct 23 10:32 streams_xattr.so
-rwxr-xr-x   1 root  wheel   42729 Oct 23 10:32 syncops.so
-rwxr-xr-x   1 root  wheel  106961 Oct 23 10:32 time_audit.so
-rwxr-xr-x   1 root  wheel   49969 Oct 23 10:33 xattr_tdb.so
-rwxr-xr-x   1 root  wheel   92441 Oct 23 10:32 zfsacl.so

When I cppy the file aio_pthread.so from the ports work dir to the destination folder samba works again.

Something goes wrong at the installation stage.

My options looks like this:
beasty samba41 # make showconfig
===> The following configuration options are available for samba41-4.1.13:
     ACL_SUPPORT=on: File system ACL support
     ADS=on: Active Directory client support
     AD_DC=on: Active Directory Domain Controller support
     AIO_SUPPORT=on: Asyncronous IO support
     CUPS=on: CUPS printing system support
     DEBUG=on: With debug information in the binaries
     DEVELOPER=off: With development support
     DNSUPDATE=on: Dynamic DNS update(require ADS)
     DOCS=on: Build and/or install documentation
     EXP_MODULES=off: Experimental modules
     FAM_SUPPORT=on: File Alteration Monitor support
     LDAP=on: LDAP client support
     MANPAGES=off: Build manpages from DOCBOOK templates
     PAM_SMBPASS=off: PAM authentication via passdb backends
     PTHREADPOOL=on: Pthread pool
     QUOTAS=on: Disk quota support
     SYSLOG=on: Syslog logging support
     UTMP=on: UTMP accounting support
====> Options available for the radio DNS: you can only select none or one of them
     NSUPDATE=on: Use samba NSUPDATE utility for AD DC
     BIND99=off: Use bind99 as AD DC DNS server frontend
====> Options available for the radio ZEROCONF: you can only select none or one of them
     AVAHI=on: Zeroconf support via Avahi
     MDNSRESPONDER=off: Zeroconf support via mDNSResponder
===> Use 'make config' to modify these settings

regards
Johan Hendriks
Comment 1 Bugzilla Automation freebsd_committer freebsd_triage 2014-10-23 09:03:58 UTC
Maintainers CC'd
Comment 2 Dominik Schubert 2014-11-02 15:56:10 UTC
I can confirm this and I'm having a similar problem with idmap_ad as well. idmap/ad.so is present in work/stage/usr/lib/shared-modules, but is not being installed (same configuration except EXP_MODULES=on).
Comment 3 Jason Mann 2014-11-03 12:24:34 UTC
I too encountered this problem on 2014-11-02 both when trying to install the samba41 package and when compiling it from ports.

Comparing the list of files under /usr/ports/net/samba41/work/stage/ with what actually gets installed indicates that only the following two files are missing:

/usr/local/lib/shared-modules/vfs/aio_posix.so
/usr/local/lib/shared-modules/vfs/aio_pthread.so
Comment 4 Timur I. Bakeyev freebsd_committer freebsd_triage 2014-11-03 15:04:00 UTC
Thanks everyone for the input. It helps to spot the typo(?) I've made with the last commit in the fix to PLIST_REINPLACE.

I used !empty(${SAMBA4_MODULES}) instead of !empty(SAMBA4_MODULES). Make logic sometimes suxx :)

The fix will follow.
Comment 5 commit-hook freebsd_committer freebsd_triage 2014-11-03 23:13:10 UTC
A commit references this bug:

Author: timur
Date: Mon Nov  3 22:53:25 UTC 2014
New revision: 372128
URL: https://svnweb.freebsd.org/changeset/ports/372128

Log:
  Fix an error in generation of the list of additional modules.

  PR:		194548

Changes:
  head/net/samba41/Makefile