Hello 
I have a Samba file server setup on an FreeBSD 12.1 with Kerberos / Winbind authentication from a Windows Server 2019 AD
Samba configuration is shown bellow in code snippet 1.
The problem I am running into is the following - after upgrading from 12.1 to 12.2, following the instructions here - https://www.freebsd.org/releases/12.2R/installation/ ,
mounting and accessing the samba shares with AD users stopped working, mapping of groups and user IDs supposedly does not work, as all the users are getting "Permission/Access denied" errors when trying to connect to the exported samba shares.
Samba services are apparently running OK, the exported shares are visible and browsable.
The only suspicious errors in the logs I am seeing are entries for sshd failing to load pam_winbind.so:
What are those symbols missing? Is pam_winbind.so broken, and if so how can I repair it? I didn't find any exact instructions on the web, do I need to reinstall some packages or rebuild them?
Any other ideas on how to debug the issue? Any help will be highly appreciated, as I spend almost 3 days now on trying to understand the cause of the issue/
Disclaimer: I am fairly new to FreeBSD, and this is a setup I inherited from the old team, so bear with me please
Thanks in advance!
======================================================
1. /usr/local/etc/samba/smb4.conf

I have a Samba file server setup on an FreeBSD 12.1 with Kerberos / Winbind authentication from a Windows Server 2019 AD
Samba configuration is shown bellow in code snippet 1.
The problem I am running into is the following - after upgrading from 12.1 to 12.2, following the instructions here - https://www.freebsd.org/releases/12.2R/installation/ ,
mounting and accessing the samba shares with AD users stopped working, mapping of groups and user IDs supposedly does not work, as all the users are getting "Permission/Access denied" errors when trying to connect to the exported samba shares.
Samba services are apparently running OK, the exported shares are visible and browsable.
Bash:
[root@fs1 ~]# service samba_server status
nmbd is running as pid 60898.
smbd is running as pid 60903.
winbindd is running as pid 60908.
The only suspicious errors in the logs I am seeing are entries for sshd failing to load pam_winbind.so:
Bash:
Apr 14 11:21:03 fs1 sshd[75370]: in try_dlopen(): /usr/local/lib/pam_winbind.so: /usr/local/lib/libp11-kit.so.0: Undefined symbol "strerror_l@FBSD_1.6"
Apr 14 11:21:03 fs1 sshd[75370]: in openpam_load_module(): no /usr/local/lib/pam_winbind.so found
Apr 14 11:21:03 fs1 sshd[75370]: fatal: PAM: initialisation failed
Apr 14 11:22:15 fs1 sshd[75382]: in try_dlopen(): /usr/local/lib/pam_winbind.so: /usr/local/lib/libp11-kit.so.0: Undefined symbol "strerror_l@FBSD_1.6"
Apr 14 11:22:15 fs1 sshd[75382]: in openpam_load_module(): no /usr/local/lib/pam_winbind.so found
Apr 14 11:22:15 fs1 sshd[75382]: fatal: PAM: initialisation failed
What are those symbols missing? Is pam_winbind.so broken, and if so how can I repair it? I didn't find any exact instructions on the web, do I need to reinstall some packages or rebuild them?
Any other ideas on how to debug the issue? Any help will be highly appreciated, as I spend almost 3 days now on trying to understand the cause of the issue/
Disclaimer: I am fairly new to FreeBSD, and this is a setup I inherited from the old team, so bear with me please
Thanks in advance!
======================================================
1. /usr/local/etc/samba/smb4.conf
Code:
log file = /var/log/samba4/clients/%m.log
log level = 3 auth:10 winbind:5
max log size = 50
#winbind separator = /
winbind cache time = 10
winbind enum users = Yes
winbind enum groups = Yes
winbind use default domain = Yes
winbind refresh tickets = Yes
winbind expand groups = 8
winbind nss info = rfc2307 sfu template
template homedir = /storage/%D/%U
template shell = /usr/local/bin/bash
idmap config *: backend = tdb
idmap config *: range = 90000001-100000000
idmap config ADP:default = Yes
idmap config ADP:backend = rid
idmap config ADP:range = 10000-90000000
load printers = No
printing = bsd
printcap name = /dev/null
disable spoolss = Yes
vfs objects = acl_xattr
map acl inherit = Yes
store dos attributes = Yes
username map = /usr/local/etc/samba/usermap.cnf
[ftpSD1]
path = /storage/ftproot
read only = no
admin users = @"REDACTED.COM\Domain Admins"
vfs objects = zfsacl,full_audit
full_audit:prefix = %u|%I|%m|%S
full_audit:success = opendir mkdir rmdir closedir open close read pread write pwrite rename unlink chmod fchmod chown fchown
full_audit:failure = connect
full_audit:facility = local7
full_audit:priority = NOTICE
[smbSD1]
path = /storage/smbroot
read only = no
admin users = @"REDACTED.COM\Domain Admins"
vfs objects = zfsacl,full_audit
full_audit:prefix = %u|%I|%m|%S
full_audit:success = opendir mkdir rmdir closedir open close read pread write pwrite rename unlink chmod fchmod chown fchown fsetxattr fset_nt_acl
full_audit:failure = connect
full_audit:facility = local7
full_audit:priority = NOTICE
#:> cat /etc/rc.conf
hostname="fs1.REDACTED.com"
ifconfig_vtnet0="inet XX.XX.XX.XX/24"
defaultrouter="XX.XX.XX.1"
sshd_enable="YES"
ntpd_enable="YES"
sendmail_enable="NO"
syslogd_enable="YES"
syslogd_flags="-ss"
samba_server_enable="YES"
samba_server_config="/usr/local/etc/samba/smb4.conf"
winbindd_enable="YES"
squid_enable="YES"
dumpdev="AUTO"
zfs_enable="YES"
qemu_guest_agent_enable="YES"
rpcbind_enable="YES"
nfs_server_enable="YES"
mountd_flags="-r"