Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 592502 - >=sys-libs/tevent-0.9.30: crashes nmbd from net-fs/samba-4.2.14
Summary: >=sys-libs/tevent-0.9.30: crashes nmbd from net-fs/samba-4.2.14
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Patrick Lauer
URL:
Whiteboard:
Keywords:
: 606820 (view as bug list)
Depends on:
Blocks:
 
Reported: 2016-08-30 22:39 UTC by Maciej Piechotka
Modified: 2018-10-26 09:54 UTC (History)
11 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Maciej Piechotka 2016-08-30 22:39:11 UTC
Thread 1 (Thread 0x7f48c30bc740 (LWP 11416)):
#0  0x00007f48bf5d2568 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
        resultvar = 0
        pid = 11416
        selftid = 11416
#1  0x00007f48bf5d39ba in __GI_abort () at abort.c:89
        save_stage = 2
        act = {__sigaction_handler = {sa_handler = 0x55a1b0a723b4, sa_sigaction = 0x55a1b0a723b4}, sa_mask = {
            __val = {94152941839184, 94152941839284, 0, 0, 0, 0, 0, 17179869184, 0, 17179869184, 0, 94152941895680, 
              0, 18446744073709551615, 335544320, 139950482632112}}, sa_flags = 1, sa_restorer = 0x0}
        sigs = {__val = {32, 0 <repeats 15 times>}}
#2  0x00007f48c1eb598a in dump_core () at ../source3/lib/dumpcore.c:337
        called = true
        __FUNCTION__ = "dump_core"
#3  0x00007f48c1ea80eb in smb_panic_s3 (why=<optimized out>) at ../source3/lib/util.c:811
        cmd = <optimized out>
        result = <optimized out>
        __FUNCTION__ = "smb_panic_s3"
#4  0x00007f48c28aa99f in smb_panic (why=why@entry=0x7f48c28b78d1 "internal error") at ../lib/util/fault.c:166
No locals.
#5  0x00007f48c28aabb6 in fault_report (sig=<optimized out>) at ../lib/util/fault.c:83
        counter = 1
#6  sig_fault (sig=<optimized out>) at ../lib/util/fault.c:94
No locals.
#7  <signal handler called>
No locals.
#8  talloc_chunk_from_ptr (ptr=0x55a1ffffffff) at ../talloc.c:429
        pp = 0x55a1ffffffff <error: Cannot access memory at address 0x55a1ffffffff>
        tc = 0x55a1ffffff9f
#9  talloc_get_size (context=0x55a1ffffffff) at ../talloc.c:2718
No locals.
#10 0x00007f48c1ebdd36 in event_add_to_poll_args (ev=0x55a1b0a800b0, mem_ctx=mem_ctx@entry=0x0, 
    pfds=pfds@entry=0x55a1af8680c8 <fds>, pnum_pfds=pnum_pfds@entry=0x7ffc3175ba48, 
    ptimeout=ptimeout@entry=0x7ffc3175ba4c) at ../source3/lib/events.c:92
        state = 0x55a1b0a82940
        fde = <optimized out>
        i = <optimized out>
        num_fds = 0
        num_pollfds = <optimized out>
        fds = <optimized out>
        now = {tv_sec = 899, tv_usec = 999035}
        diff = <optimized out>
        timeout = <optimized out>
        __FUNCTION__ = "event_add_to_poll_args"
#11 0x000055a1af64673f in listen_for_packets (msg=0x55a1b0a801e0, run_election=<optimized out>)
    at ../source3/nmbd/nmbd_packets.c:1939
        fds = 0x55a1b0a88660
        attrs = 0x55a1b0a88700
        listen_number = 6
        num_sockets = 6
        i = <optimized out>
        timeout = 1000
        dns_fd = -1
        dns_pollidx = -1
        processed_packet_list = 0x0
        __FUNCTION__ = "listen_for_packets"
#12 0x000055a1af635b86 in process (msg=<optimized out>) at ../source3/nmbd/nmbd.c:526
        t = 1472595944
        frame = 0x55a1b0a70740
        run_election = <optimized out>
#13 main (argc=<optimized out>, argv=<optimized out>) at ../source3/nmbd/nmbd.c:1101
        is_daemon = <optimized out>
        opt_interactive = false
        Fork = <optimized out>
        no_process_group = false
        log_stdout = <optimized out>
        pc = <optimized out>
        p_lmhosts = 0x0
        opt = <optimized out>
        msg = 0x55a1b0a801e0
        long_options = {{longName = 0x0, shortName = 0 '\000', argInfo = 4, arg = 0x7f48bff70400 <poptHelpOptions>, 
            val = 0, descrip = 0x55a1af652344 "Help options:", argDescrip = 0x0}, {
            longName = 0x55a1af652352 "daemon", shortName = 68 'D', argInfo = 0, arg = 0x0, val = 1000, 
            descrip = 0x55a1af652359 "Become a daemon(default)", argDescrip = 0x0}, {
            longName = 0x55a1af652372 "interactive", shortName = 105 'i', argInfo = 0, arg = 0x0, val = 1001, 
            descrip = 0x55a1af6528e0 "Run interactive (not a daemon)", argDescrip = 0x0}, {
            longName = 0x55a1af65237e "foreground", shortName = 70 'F', argInfo = 0, arg = 0x0, val = 1002, 
            descrip = 0x55a1af652900 "Run daemon in foreground (for daemontools & etc)", argDescrip = 0x0}, {
            longName = 0x55a1af652389 "no-process-group", shortName = 0 '\000', argInfo = 0, arg = 0x0, val = 1003, 
            descrip = 0x55a1af652938 "Don't create a new process group", argDescrip = 0x0}, {
            longName = 0x55a1af65239a "log-stdout", shortName = 83 'S', argInfo = 0, arg = 0x0, val = 1004, 
            descrip = 0x55a1af6523a5 "Log to stdout", argDescrip = 0x0}, {longName = 0x55a1af6523b3 "hosts", 
            shortName = 72 'H', argInfo = 1, arg = 0x7ffc3175baa8, val = 0, 
            descrip = 0x55a1af6523b9 "Load a netbios hosts file", argDescrip = 0x0}, {
            longName = 0x55a1af6523eb "port", shortName = 112 'p', argInfo = 2, 
            arg = 0x55a1af86801c <global_nmb_port>, val = 0, descrip = 0x55a1af6523d3 "Listen on the specified port", 
            argDescrip = 0x0}, {longName = 0x0, shortName = 0 '\000', argInfo = 4, 
            arg = 0x7f48c2cc84c0 <popt_common_samba>, val = 0, descrip = 0x55a1af6523f0 "Common samba options:", 
            argDescrip = 0x0}, {longName = 0x0, shortName = 0 '\000', argInfo = 0, arg = 0x0, val = 0, descrip = 0x0, 
            argDescrip = 0x0}}
        frame = <optimized out>
        status = <optimized out>
        ok = <optimized out>
        __FUNCTION__ = "main"

Portage 2.3.0 (python 3.4.5-final-0, default/linux/amd64/13.0, gcc-5.4.0, glibc-2.23-r2, 4.7.2-gentoo-efi x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.7.2-gentoo-efi-x86_64-Intel-R-_Core-TM-_i7-3930K_CPU_@_3.20GHz-with-gentoo-2.2
KiB Mem:    16437172 total,   2980024 free                                                                             
KiB Swap:   16777212 total,  16773564 free                                                                             Timestamp of repository gentoo: Tue, 30 Aug 2016 19:00:01 +0000                                                        sh bash 4.3_p46
ld GNU ld (Gentoo 2.25.1 p1.1) 2.25.1                                                                                  distcc 3.2rc1 x86_64-pc-linux-gnu [disabled]                                                                           app-shells/bash:          4.3_p46::gentoo                                                                              
dev-lang/perl:            5.24.0-r1::gentoo                                                                            dev-lang/python:          2.7.12::gentoo, 3.4.5::gentoo                                                                dev-util/cmake:           3.6.1::gentoo                                                                                dev-util/pkgconfig:       0.29.1::gentoo                                                                               sys-apps/baselayout:      2.2-r1::gentoo                                                                               sys-apps/openrc:          0.21.5::gentoo                                                                               sys-apps/sandbox:         2.10-r2::gentoo                                                                              sys-devel/autoconf:       2.13::gentoo, 2.69-r2::gentoo                                                                sys-devel/automake:       1.13.4-r1::gentoo, 1.14.1-r1::gentoo, 1.15-r2::gentoo                                        sys-devel/binutils:       2.25.1-r1::gentoo, 2.26.1::gentoo                                                            sys-devel/gcc:            5.3.0::gentoo, 5.4.0::gentoo                                                                 sys-devel/gcc-config:     1.8-r1::gentoo                                                                               sys-devel/libtool:        2.4.6-r2::gentoo                                                                             sys-devel/make:           4.2.1::gentoo                                                                                sys-kernel/linux-headers: 4.7::gentoo (virtual/os-headers)                                                             sys-libs/glibc:           2.23-r2::gentoo                                                                              
Repositories:                                                                                                           
(...)
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=native -pipe -ggdb"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.0/ext-active/ /etc/php/cgi-php7.0/ext-active/ /etc/php/cli-php7.0/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"                                                                                      CXXFLAGS="-O2 -march=native -pipe -ggdb"
DISTDIR="/var/tmp/distfiles"
EMERGE_DEFAULT_OPTS="-j12 --load-average=11"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs clean-logs compress-build-logs compressdebug config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms split-elog splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"             FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://mirror.netcologne.de/gentoo/ ftp://mirror.netcologne.de/gentoo/"
LANG="en_GB.UTF-8"                                                                                                     LC_ALL="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--hash-style=both -Wl,--sort-common"
MAKEOPTS="-j12 -l11"     
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"                                                                                                                     PORTAGE_TMPDIR="/var/tmp"
USE="X acl acpi amd64 berkdb bindist bzip2 cli cracklib crypt cxx dri emacs fortran gdbm gssapi iconv ipv6 kerberos mmx mmxext modules multilib ncurses nls nptl openldap openmp pam pcre python readline samba sasl seccomp session sse sse2 ssl systemd tcpd unicode vim vim-syntax xattr zlib" ABI_X86="32 64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="pc efi-32 efi-64" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby20 ruby21" USERLAND="GNU" VIDEO_CARDS="nouveax" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"                                                                                         Unset:  CC, CPPFLAGS, CTARGET, CXX, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON                                                                                      
=================================================================
                        Package Settings
=================================================================
    
sys-libs/tevent-0.9.29::gentoo was built with the following:
USE="python" ABI_X86="32 64 -x32" PYTHON_TARGETS="python2_7"
Comment 1 iGentoo 2016-09-01 03:48:09 UTC
Same problem.

# journalctl -k:

Sep 01 11:29:32 iGentoo kernel: PAX: execution attempt in: (null), 00000000-00000000 00000000
Sep 01 11:29:32 iGentoo kernel: PAX: terminating task: /usr/sbin/smbd(cleanupd):30901, uid/euid: 0/0, PC:            (nil), SP: 000003978a51ace8
Sep 01 11:29:32 iGentoo kernel: PAX: bytes at PC: ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? 
Sep 01 11:29:32 iGentoo kernel: PAX: bytes at SP-8: 0000000000000002 0000031782a3c5d0 0000000057c7a09c 000000000009ac63 0000000000000000 0000000000000000 0000
Sep 01 11:29:32 iGentoo kernel: grsec: bruteforce prevention initiated for the next 30 minutes or until service restarted, stalling each fork 30 seconds.  Ple
Sep 01 11:35:21 iGentoo kernel: zram: Added device: zram0


# cat /var/log/samba/smbd.log 
[2016/09/01 11:29:32.632751,  0] ../lib/util/fault.c:78(fault_report)
  ===============================================================
[2016/09/01 11:29:32.632812,  0] ../lib/util/fault.c:79(fault_report)
  INTERNAL ERROR: Signal 11 in pid 30900 (4.4.5)
  Please read the Trouble-Shooting section of the Samba HOWTO
[2016/09/01 11:29:32.632834,  0] ../lib/util/fault.c:81(fault_report)
  ===============================================================
[2016/09/01 11:29:32.632857,  0] ../source3/lib/util.c:791(smb_panic_s3)
  PANIC (pid 30900): internal error
[2016/09/01 11:29:32.633605,  0] ../source3/lib/util.c:902(log_stack_trace)
  BACKTRACE: 14 stack frames:
   #0 /usr/lib64/libsmbconf.so.0(log_stack_trace+0x1c) [0x31782db324c]
   #1 /usr/lib64/libsmbconf.so.0(smb_panic_s3+0x20) [0x31782db3320]
   #2 /usr/lib64/libsamba-util.so.0(smb_panic+0x2f) [0x31783744fdf]
   #3 /usr/lib64/libsamba-util.so.0(+0x231f6) [0x317837451f6]
   #4 /lib64/libpthread.so.0(+0x10e10) [0x317833c3e10]
   #5 /usr/lib64/libtevent.so.0(tevent_debug+0x56) [0x31782a38016]
   #6 /usr/lib64/libtevent.so.0(tevent_common_loop_timer_delay+0xba) [0x31782a3c5ba]
   #7 /usr/lib64/libsmbconf.so.0(run_events_poll+0x1a9) [0x31782dc9109]
   #8 /usr/lib64/libsmbconf.so.0(+0x362a7) [0x31782dc92a7]
   #9 /usr/lib64/libtevent.so.0(_tevent_loop_once+0x9d) [0x31782a37bdd]
   #10 /usr/lib64/libtevent.so.0(tevent_req_poll+0x23) [0x31782a38f23]
   #11 /usr/sbin/smbd(main+0x9d8) [0x7bbd0fd78]
   #12 /lib64/libc.so.6(__libc_start_main+0xf1) [0x317826bb681]
   #13 /usr/sbin/smbd(_start+0x29) [0x7bbd10cf9]
[2016/09/01 11:29:32.633717,  0] ../source3/lib/dumpcore.c:303(dump_core)
  dumping core in /var/log/samba/cores/smbd
[2016/09/01 11:30:02.641106,  0] ../lib/util/become_daemon.c:124(daemon_ready)
  STATUS=daemon 'smbd' finished starting up and ready to serve connections
[2016/09/01 11:35:28.296770,  0] ../lib/util/become_daemon.c:124(daemon_ready)
  STATUS=daemon 'smbd' finished starting up and ready to serve connections



# emerge --info samba tevent tdb
Portage 2.3.0 (python 3.5.2-final-0, default/linux/amd64/13.0, gcc-6.2.0, glibc-2.23-r2, 4.7.2-hardened.x86_64 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.7.2-hardened.x86_64-x86_64-Intel-R-_Core-TM-2_Quad_CPU_Q9300_@_2.50GHz-with-gentoo-2.2
KiB Mem:     6114180 total,    797296 free
KiB Swap:    6291452 total,   6290892 free
sh dash 0.5.9
ld GNU gold (Gentoo 2.26.1 p1.0 2.26.1) 1.11
ccache version 3.3 [disabled]
app-shells/bash:          4.4_rc2::gentoo
dev-java/java-config:     2.2.0-r3::gentoo
dev-lang/perl:            5.24.0-r1::gentoo
dev-lang/python:          2.7.12::gentoo, 3.5.2::gentoo
dev-util/ccache:          3.3::local-repo
dev-util/cmake:           3.6.1-r1::gentoo
dev-util/pkgconfig:       0.29.1::gentoo
sys-apps/baselayout:      2.2-r1::gentoo
sys-apps/sandbox:         2.11-r2::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69-r2::gentoo
sys-devel/automake:       1.15-r2::gentoo
sys-devel/binutils:       2.26.1::gentoo
sys-devel/gcc:            6.2.0::local-repo
sys-devel/gcc-config:     1.8-r1::gentoo
sys-devel/libtool:        2.4.6-r2::gentoo
sys-devel/make:           4.2.1::gentoo
sys-kernel/linux-headers: 4.7::gentoo (virtual/os-headers)
sys-libs/glibc:           2.23-r2::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: git
    sync-uri: git://anongit.gentoo.org/repo/gentoo.git
    priority: -1000
    eclass-overrides: local-repo

local-repo
    location: /usr/local/portage
    masters: gentoo

Installed sets: @local
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-Wall -march=native -O2 -pipe -frecord-gcc-switches"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-Wall -march=native -O2 -pipe -frecord-gcc-switches"
DISTDIR="/var/portage/distfiles"
EMERGE_DEFAULT_OPTS="--color=n --oneshot"
FCFLAGS="-Wall -march=native -O2 -pipe -frecord-gcc-switches"
FEATURES="assume-digests binpkg-logs buildpkg collision-protect config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync metadata-transfer multilib-strict news parallel-fetch preserve-libs protect-owned sandbox sfperms split-log strict test-fail-continue unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync webrsync-gpg xattr"
FFLAGS="-Wall -march=native -O2 -pipe -frecord-gcc-switches"
GENTOO_MIRRORS="http://mirrors.163.com/gentoo http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="V=1 -j6"
PKGDIR="/var/portage/packages"
PORTAGE_BZIP2_COMMAND="lbzip2"
PORTAGE_COMPRESS="xz"
PORTAGE_COMPRESS_FLAGS="-9T0"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="X acl amd64 audit berkdb bzip2 cli cracklib crypt cxx dbus dri egl fortran gdbm gles2 iconv icu ipv6 jpeg mmx mmxext modules multilib ncurses nls nptl opengl openmp pam pax_kernel pcre pic png policykit pulseaudio readline seccomp session sse sse2 ssl systemd tcpd unicode vdpau vim-syntax wayland xattr zlib" ABI_X86="64 32 x32" ALSA_CARDS="hda-intel" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2 sse3 sse4_1 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev" KERNEL="linux" L10N="zh-CN" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="zh_CN" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" PYTHON_SINGLE_TARGET="python3_5" PYTHON_TARGETS="python2_7 python3_5" RUBY_TARGETS="ruby23" USERLAND="GNU" VIDEO_CARDS="nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

=================================================================
                        Package Settings
=================================================================

net-fs/samba-4.4.5::gentoo was built with the following:
USE="acl client pam system-mitkrb5 systemd -addc -addns -ads -avahi -cluster -cups -dmapi -fam -gnutls -iprint -ldap -quota (-selinux) -syslog -test -winbind" ABI_X86="64 -32 -x32" PYTHON_TARGETS="python2_7"


sys-libs/tevent-0.9.30::gentoo was built with the following:
USE="python" ABI_X86="32 64 x32" PYTHON_TARGETS="python2_7"


sys-libs/tdb-1.3.11::local-repo was built with the following:
USE="python" ABI_X86="32 64 x32" PYTHON_TARGETS="python2_7"
Comment 2 Alesc 2016-09-01 14:05:42 UTC
I was banging my head on this one for two days, and you gave me the solution !
I do confirm that sys-libs/tevent-0.9.29 is working an sys-libs/tevent-0.9.30 makes nmbd crash :

===============================================================
INTERNAL ERROR: Signal 11 in pid 18218 (4.2.14)
Please read the Trouble-Shooting section of the Samba HOWTO
===============================================================
PANIC (pid 18218): internal error
BACKTRACE: 11 stack frames:
 #0 /usr/lib64/libsmbconf.so.0(log_stack_trace+0x1a) [0x7fcfd2680eaa]
 #1 /usr/lib64/libsmbconf.so.0(smb_panic_s3+0x20) [0x7fcfd2680f80]
 #2 /usr/lib64/libsamba-util.so.0(smb_panic+0x2f) [0x7fcfd307d74f]
 #3 /usr/lib64/libsamba-util.so.0(+0x19966) [0x7fcfd307d966]
 #4 /lib64/libpthread.so.0(+0x10e10) [0x7fcfd34ace10]
 #5 /usr/lib64/libtalloc.so.2(talloc_get_size+0x5) [0x7fcfd096e2c5]
 #6 /usr/lib64/libsmbconf.so.0(event_add_to_poll_args+0x76) [0x7fcfd2696be6]
 #7 nmbd(listen_for_packets+0xff) [0x55d3a0ebf02f]
 #8 nmbd(main+0xcf6) [0x55d3a0eae476]
 #9 /lib64/libc.so.6(__libc_start_main+0xf0) [0x7fcfcfda9710]
 #10 nmbd(_start+0x29) [0x55d3a0eae839]
dumping core in /var/log/samba/cores/nmbd
Aborted (core dumped)
Comment 3 Per Pomsel 2016-09-02 05:10:57 UTC
I can confirm the crash. I had to switch back to sys-libs/tevent-0.9.29.
Comment 4 Alessandro Rosetti 2016-09-02 10:08:39 UTC
I can also confirm the bug. solution rollback to sys-libs/tevent-0.9.29.
Comment 5 brankob 2016-09-02 17:09:57 UTC
Same here. It took me a couple of days to locate the problem :o(

With tevent-0.9.30 Samba crashes. I tested it with samba-3.6.25 as well as with v4.4.5. With tevent 0.9.30 both crash the same way and even in the intervals between crashes ( if they don't crash at start) behave the same.

And with both downgrading tevent to v0.9.29 solves the issue.
Comment 6 Chris Smith 2016-09-06 14:54:16 UTC
I compile Samba locally from git and have this issue as well.

# nmbd -FS
nmbd version 4.4.6-GIT-1305ba6 started.
Copyright Andrew Tridgell and the Samba Team 1992-2016
STATUS=daemon 'nmbd' finished starting up and ready to serve connections
===============================================================
INTERNAL ERROR: Signal 11 in pid 11238 (4.4.6-GIT-1305ba6)
Please read the Trouble-Shooting section of the Samba HOWTO
===============================================================
PANIC (pid 11238): internal error
BACKTRACE: 13 stack frames:
 #0 /usr/local/samba/lib/libsmbconf.so.0(log_stack_trace+0x1f) [0x7f3fe2250a81]
 #1 /usr/local/samba/lib/libsmbconf.so.0(smb_panic_s3+0x6d) [0x7f3fe22508d2]
 #2 /usr/local/samba/lib/libsamba-util.so.0(smb_panic+0x28) [0x7f3fe2cb7004]
 #3 /usr/local/samba/lib/libsamba-util.so.0(+0x20ce2) [0x7f3fe2cb6ce2]
 #4 /usr/local/samba/lib/libsamba-util.so.0(+0x20cf7) [0x7f3fe2cb6cf7]
 #5 /lib64/libpthread.so.0(+0x10d90) [0x7f3fe3127d90]
 #6 /usr/lib64/libtalloc.so.2(talloc_get_size+0x5) [0x7f3fe03163c5]
 #7 /usr/local/samba/lib/libsmbconf.so.0(event_add_to_poll_args+0x72) 
[0x7f3fe226bf81]
 #8 nmbd(listen_for_packets+0x230) [0x56036fb9f2b1]
 #9 nmbd(+0x9bdf) [0x56036fb88bdf]
 #10 nmbd(main+0xe17) [0x56036fb89e04]
 #11 /lib64/libc.so.6(__libc_start_main+0xf0) [0x7f3fdf74a720]
 #12 nmbd(_start+0x29) [0x56036fb86e59]
smb_panic(): calling panic action [/bin/sleep 90000]

# smbd -FS                                                                       
smbd version 4.4.6-GIT-1305ba6 started.
Copyright Andrew Tridgell and the Samba Team 1992-2016
===============================================================
INTERNAL ERROR: Signal 11 in pid 11198 (4.4.6-GIT-1305ba6)
Please read the Trouble-Shooting section of the Samba HOWTO
===============================================================
PANIC (pid 11198): internal error
===============================================================
INTERNAL ERROR: Signal 11 in pid 11199 (4.4.6-GIT-1305ba6)
Please read the Trouble-Shooting section of the Samba HOWTO
===============================================================
PANIC (pid 11199): internal error
BACKTRACE: 16 stack frames:
 #0 /usr/local/samba/lib/libsmbconf.so.0(log_stack_trace+0x1f) [0x7efe57c8ca81]
 #1 /usr/local/samba/lib/libsmbconf.so.0(smb_panic_s3+0x6d) [0x7efe57c8c8d2]
 #2 /usr/local/samba/lib/libsamba-util.so.0(smb_panic+0x28) [0x7efe5a2bb004]
 #3 /usr/local/samba/lib/libsamba-util.so.0(+0x20ce2) [0x7efe5a2bace2]
 #4 /usr/local/samba/lib/libsamba-util.so.0(+0x20cf7) [0x7efe5a2bacf7]
 #5 /lib64/libpthread.so.0(+0x10d90) [0x7efe5a526d90]
 #6 /usr/lib64/libtevent.so.0(tevent_debug+0x5e) [0x7efe564f405e]
 #7 /usr/lib64/libtevent.so.0(tevent_common_loop_timer_delay+0xba) 
[0x7efe564f862a]
 #8 /usr/local/samba/lib/libsmbconf.so.0(run_events_poll+0x76) [0x7efe57ca83a9]
 #9 /usr/local/samba/lib/libsmbconf.so.0(+0x3b9f7) [0x7efe57ca89f7]
 #10 /usr/lib64/libtevent.so.0(_tevent_loop_once+0x9d) [0x7efe564f3c1d]
 #11 /usr/lib64/libtevent.so.0(tevent_req_poll+0x1f) [0x7efe564f4fbf]
 #12 smbd(+0x75ea) [0x55e4354375ea]
 #13 smbd(main+0xf5a) [0x55e43543a7c5]
 #14 /lib64/libc.so.6(__libc_start_main+0xf0) [0x7efe56170720]
 #15 smbd(_start+0x29) [0x55e435435b19]
smb_panic(): calling panic action [/bin/sleep 90000]
BACKTRACE: 6 stack frames:
 #0 /usr/local/samba/lib/libsmbconf.so.0(log_stack_trace+0x1f) [0x7efe57c8ca81]
 #1 /usr/local/samba/lib/libsmbconf.so.0(smb_panic_s3+0x6d) [0x7efe57c8c8d2]
 #2 /usr/local/samba/lib/libsamba-util.so.0(smb_panic+0x28) [0x7efe5a2bb004]
 #3 /usr/local/samba/lib/libsamba-util.so.0(+0x20ce2) [0x7efe5a2bace2]
 #4 /usr/local/samba/lib/libsamba-util.so.0(+0x20cf7) [0x7efe5a2bacf7]
 #5 /lib64/libpthread.so.0(+0x10d90) [0x7efe5a526d90]
smb_panic(): calling panic action [/bin/sleep 90000]

Reported to Samba list:
http://www.spinics.net/lists/samba/msg136922.html
Comment 7 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2016-09-06 18:23:00 UTC
$ grep -FB2 "sys-libs/tevent" ../../profiles/package.mask
# Lars Wendler <polynomial-c@gentoo.org> (06 Sep 2016)
# Breaks samba's nmbd process (bug #592502)
=sys-libs/tevent-0.9.30
Comment 8 Chris Smith 2016-09-06 21:02:36 UTC
I think the issue is that Samba doesn't compile against the system version of tevent, it compiles against it's internal version yet uses the system version when running.

"Just dropping tevent-0.9.30 into an existing Samba installation
without recompiling Samba is invalid. Maybe we should document that
better, but Samba makes use of internal tevent structures that we give
no ABI guarantees for. See the comment in tevent_internal.h:

   INTERNAL STRUCTS. THERE ARE NO API GUARANTEES.
   External users should only ever have to include this header when
   implementing new tevent backends."
Comment 9 Reuben Martin 2016-09-07 20:22:57 UTC
(In reply to Chris Smith from comment #8)
> "Just dropping tevent-0.9.30 into an existing Samba installation
> without recompiling Samba is invalid. 


Recompliling Samba make no difference.
Comment 10 Chris Smith 2016-09-07 20:37:42 UTC
(In reply to Reuben Martin from comment #9)
> (In reply to Chris Smith from comment #8)
> > "Just dropping tevent-0.9.30 into an existing Samba installation
> > without recompiling Samba is invalid. 
> 
> 
> Recompliling Samba make no difference.

That's because it still doesn't compile against tevent-0.9.30. Replace the tevent_internal.h file in the Samba source with the one from the tevent-0.9.30 source and then recompile.
Comment 11 Vladimír Čunát 2016-09-28 22:14:44 UTC
What baffles me that although [1] claims that tevent should install the internal header, the (upstream) tevent package itself doesn't try to do so and therefore the problem isn't really Gentoo-specific [2].

[1] https://www.spinics.net/lists/samba/msg136998.html
[2] https://github.com/NixOS/nixpkgs/issues/19013
Comment 12 liva 2016-10-20 18:40:37 UTC
also =sys-libs/tevent-0.9.31
Comment 13 email200202 2016-10-21 03:01:36 UTC
Same here: update to sys-libs/tevent-0.9.31  from 0.9.29 caused nmbd to crash. When downgraded back to 0.9.29, nmbd started working again.
Comment 14 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2016-10-21 06:42:29 UTC
commit 50f3094df82ced5fcc337f90f5c921c681d21b51
Author: Lars Wendler <polynomial-c@gentoo.org>
Date:   Fri Oct 21 08:40:33 2016

    package.mask: Adjusted mask on tevent (bug #592502).
Comment 15 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2016-10-21 09:01:23 UTC
commit b6e37bd91931f7a1a7ccace759a208813207ca0f
Author: Lars Wendler <polynomial-c@gentoo.org>
Date:   Fri Oct 21 11:00:10 2016

    net-fs/samba: Revbump to fix nmbd segfault with >=tevent-0.9.30

    See Gentoo bug #592502

    Package-Manager: portage-2.3.2
    Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>


commit 6b94c3983ebd97e9a98a3ccb1b37f8d74ad6817e
Author: Lars Wendler <polynomial-c@gentoo.org>
Date:   Fri Oct 21 10:55:34 2016

    sys-libs/tevent: Revbump to install tevent_internal.h for bug #592502.

    Package-Manager: portage-2.3.2
    Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>


If you want to test this you must unmask both =tevent-0.9.31-r1 and =samba-4.5.0-r1
Comment 16 Ivan Grynko 2016-10-21 12:07:09 UTC
(In reply to Lars Wendler (Polynomial-C) from comment #15)
> commit b6e37bd91931f7a1a7ccace759a208813207ca0f
> Author: Lars Wendler <polynomial-c@gentoo.org>
> Date:   Fri Oct 21 11:00:10 2016
> 
>     net-fs/samba: Revbump to fix nmbd segfault with >=tevent-0.9.30
> 
>     See Gentoo bug #592502
> 
>     Package-Manager: portage-2.3.2
>     Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
> 
> 
> commit 6b94c3983ebd97e9a98a3ccb1b37f8d74ad6817e
> Author: Lars Wendler <polynomial-c@gentoo.org>
> Date:   Fri Oct 21 10:55:34 2016
> 
>     sys-libs/tevent: Revbump to install tevent_internal.h for bug #592502.
> 
>     Package-Manager: portage-2.3.2
>     Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
> 
> 
> If you want to test this you must unmask both =tevent-0.9.31-r1 and
> =samba-4.5.0-r1

Tested sys-libs/tevent-0.9.31-r1 with net-fs/samba-4.5.0-r1 no more nmbd crashes.
Comment 17 Conrad Kostecki gentoo-dev 2016-10-21 15:06:58 UTC
(In reply to Ivan Ivanich from comment #16)
> (In reply to Lars Wendler (Polynomial-C) from comment #15)
> > commit b6e37bd91931f7a1a7ccace759a208813207ca0f
> > Author: Lars Wendler <polynomial-c@gentoo.org>
> > Date:   Fri Oct 21 11:00:10 2016
> > 
> >     net-fs/samba: Revbump to fix nmbd segfault with >=tevent-0.9.30
> > 
> >     See Gentoo bug #592502
> > 
> >     Package-Manager: portage-2.3.2
> >     Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
> > 
> > 
> > commit 6b94c3983ebd97e9a98a3ccb1b37f8d74ad6817e
> > Author: Lars Wendler <polynomial-c@gentoo.org>
> > Date:   Fri Oct 21 10:55:34 2016
> > 
> >     sys-libs/tevent: Revbump to install tevent_internal.h for bug #592502.
> > 
> >     Package-Manager: portage-2.3.2
> >     Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
> > 
> > 
> > If you want to test this you must unmask both =tevent-0.9.31-r1 and
> > =samba-4.5.0-r1
> 
> Tested sys-libs/tevent-0.9.31-r1 with net-fs/samba-4.5.0-r1 no more nmbd
> crashes.

+1 works for me too.
Comment 18 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2017-01-25 16:51:41 UTC
*** Bug 606820 has been marked as a duplicate of this bug. ***
Comment 19 Virgil Dupras (RETIRED) gentoo-dev 2018-10-08 12:12:26 UTC
Not masked anymore.