Category: Samba

Building Samba 4.12 on Centos 7

Samba has some new dependencies which are not so easily fulfilled on Centos 7. You’ll need Python 3 and Nettle and GnuTLS-Devel-Packages which conflict with installed packages. Luckily there are “compat” packages, for example at the repository:

My shell script to build Samba looks like this, note the export-Statement:

export PKG_CONFIG_PATH=/usr/lib64/compat-gnutls34/pkgconfig:/usr/lib64/compat-nettle32/pkgconfig

./configure –disable-python –without-ads –disable-cups –without-json –without-libarchive –disable-iprint –with-systemd –without-winbind –without-ad-dc –without-ldap –prefix=/ –sysconfdir=/etc/samba –with-logfilebase=/var/log/samba –with-piddir=/var/run –with-privatedir=/var/lib/samba/private –includedir=/usr/include –sharedstatedir=/usr/share –with-lockdir=/run/lock/samba

make && make smbclient && make install && make clean && make distclean

Samba 4.10 exiting quietly while Samba 4.9 works

On my Centos-7-server I’m compiling samba as a file server. This worked well up to version 4.9. After 4.10 was released, I did my compile routine, started smbd and it exited immediately and quietly. Even with debug output and in a debug build there was no conclusive output. Looking through the samba sources there where some points where the smbd server process exits without printing some message. so I started instrumenting this exits and working up the call tree to the point where the lock dir gets set. I did not change this via configure, so it was the default /var/lock which worked well for version 4.9, but version 4.10 and up need the configure option --with-lockdir=/var/run/lock/samba to run, why I did not fathom. Now everything works again.