[nsd-users] NSD 4.2.0 intermittent segfaults @ libssl ?

A. Schulze sca at andreasschulze.de
Wed Jun 12 17:56:20 UTC 2019



Am 12.06.19 um 18:46 schrieb Stuart Henderson:
> On 2019/06/12 18:38, A. Schulze wrote:
>>
>>
>> Am 12.06.19 um 08:16 schrieb Wouter Wijngaards:
>>> Otherwise, perhaps a stack trace of the issue could be useful
>>> to have, or a way to reproduce it.
>>
>> I'm unable to produce core files.
>>
>> - ulimit -c unlimited is set
>> - cat /proc/sys/kernel/core_pattern: /core/corefile
>>
>> /core exist outside and inside chroot and is writeable by nsd user
>> nsd started chroot and without chroot
>> nsd crash but: no corefile :-/
>>
>> Any more magic required?
> 
> Try running nsd in the foreground directly under gdb?

OK here some result:

I use to start nsd as "nsd -d -c /path/to/nsd.conf

this start 3 processes
33786 ?        Ss     0:00  \_ sshd: root at pts/1
33798 pts/1    Ss     0:00  |   \_ -bash
30910 pts/1    S+     0:00  |       \_ /usr/sbin/nsd -c /chroot/etc/nsd/nsd.conf
30911 pts/1    S+     0:00  |           \_ /usr/sbin/nsd -c /chroot/etc/nsd/nsd.conf
32456 pts/1    S+     0:00  |               \_ /usr/sbin/nsd -c /chroot/etc/nsd/nsd.conf

# gdb /usr/sbin/nsd
GNU gdb (Debian 7.12-6) 7.12.0.20161007-git
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/sbin/nsd...(no debugging symbols found)...done.
(gdb) attach 32456
Attaching to program: /usr/sbin/nsd, process 32456
Reading symbols from /lib/x86_64-linux-gnu/libssl.so.1.1...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libprotobuf-c.so.1...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libfstrm.so.0...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libcrypto.so.1.1...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libev.so.4...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libc.so.6...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libdl.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libpthread.so.0...(no debugging symbols found)...done.
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Reading symbols from /lib/x86_64-linux-gnu/libm.so.6...(no debugging symbols found)...done.
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libnss_compat.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libnsl.so.1...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libnss_nis.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/x86_64-linux-gnu/libnss_files.so.2...(no debugging symbols found)...done.
0x00007ffbed5602e3 in epoll_wait () from /lib/x86_64-linux-gnu/libc.so.6
(gdb) continue
Continuing.

{{{{{ now I start "nsd_control force_transfer" @ the SLAVE-Server ... }}}}

Program received signal SIGSEGV, Segmentation fault.
0x00007ffbee331785 in SSL_shutdown () from /lib/x86_64-linux-gnu/libssl.so.1.1
(gdb) bt
#0  0x00007ffbee331785 in SSL_shutdown () from /lib/x86_64-linux-gnu/libssl.so.1.1
#1  0x000055d50cb2ce0e in ?? ()
#2  0x000055d50cb2dfd8 in ?? ()
#3  0x00007ffbed81a413 in ev_invoke_pending () from /lib/x86_64-linux-gnu/libev.so.4
#4  0x00007ffbed81da06 in ev_run () from /lib/x86_64-linux-gnu/libev.so.4
#5  0x00007ffbed81ffd9 in event_base_loop () from /lib/x86_64-linux-gnu/libev.so.4
#6  0x000055d50cb30bdd in ?? ()
#7  0x000055d50cb30fcb in ?? ()
#8  0x000055d50cb3244c in ?? ()
#9  0x000055d50cae3ff7 in ?? ()
#10 0x00007ffbed4972e1 in __libc_start_main () from /lib/x86_64-linux-gnu/libc.so.6
#11 0x000055d50cae45fa in ?? ()
(gdb) quit
A debugging session is active.

        Inferior 1 [process 32456] will be detached.

Quit anyway? (y or n) y
Detaching from program: /usr/sbin/nsd, process 32456

Hope, this helps ...

Andreas



More information about the nsd-users mailing list