Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1047982

Summary: segfault in ns-slapd when installing IPA
Product: Red Hat Enterprise Linux 7 Reporter: Michael Gregg <mgregg>
Component: 389-ds-baseAssignee: Rich Megginson <rmeggins>
Status: CLOSED DUPLICATE QA Contact: Sankar Ramalingam <sramling>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.0CC: mgregg, nhosoi, nkinder
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-07 22:51:33 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Michael Gregg 2014-01-02 19:50:02 UTC
Description of problem:

During IPA install, segfaults come up in /var/log/messages.

Looks to be related to libpthread

Version-Release number of selected component (if applicable):
389-ds-base-1.3.1.6-12.el7.x86_64

How reproducible:
Unknown

Steps to Reproduce:
1. install a IPA master.
2. create gpg file for installing a replica.
3. Install replica with that gpg file similar to: ipa-replica-install -U --setup-dns --forwarder=<dns server> -w <pw> -p <pw> /opt/rhqa_ipa/replica-info-ipaqavmd.testrelm.com.gpg

Actual results:
[root@ipaqavmd ~]# grep segfault /var/log/messages 
Jan  2 14:12:00 ipaqavmd kernel: [  970.897796] ns-slapd[18289]: segfault at 10 ip 00007faf1e510bd1 sp 00007fff863cee28 error 4 in libpthread-2.17.so[7faf1e507000+16000]
Jan  2 14:14:06 ipaqavmd kernel: [ 1096.711612] ns-slapd[18513]: segfault at 10 ip 00007f040088dbd1 sp 00007fffd65520e8 error 4 in libpthread-2.17.so[7f0400884000+16000]
Jan  2 14:18:14 ipaqavmd kernel: [ 1344.474198] ns-slapd[19767]: segfault at 10 ip 00007f51593abbd1 sp 00007fff306ed718 error 4 in libpthread-2.17.so[7f51593a2000+16000]
Jan  2 14:28:56 ipaqavmd kernel: [ 1986.900127] ns-slapd[23295]: segfault at 10 ip 00007f19bcb14bd1 sp 00007f198f7f3828 error 4 in libpthread-2.17.so[7f19bcb0b000+16000]

More info:

Jan  2 14:11:47 ipaqavmd systemd: Stopping 389 Directory Server TESTRELM-COM....
Jan  2 14:11:48 ipaqavmd systemd: Starting 389 Directory Server TESTRELM-COM....
Jan  2 14:11:48 ipaqavmd systemd: Started 389 Directory Server TESTRELM-COM..
Jan  2 14:11:49 ipaqavmd logger: 2014-01-02 14:11:49 /usr/bin/rhts-test-runner.sh 84740 960 hearbeat...
Jan  2 14:11:59 ipaqavmd systemd: Reloading.
Jan  2 14:11:59 ipaqavmd systemd: [/usr/lib/systemd/system/beah-srv.service:4] Failed to add dependency on beah-beaker-backend, ignoring: Invalid argument
Jan  2 14:11:59 ipaqavmd systemd: [/usr/lib/systemd/system/beah-srv.service:4] Failed to add dependency on beah-fwd-backend, ignoring: Invalid argument
Jan  2 14:11:59 ipaqavmd systemd: Reloading.
Jan  2 14:11:59 ipaqavmd systemd: [/usr/lib/systemd/system/beah-srv.service:4] Failed to add dependency on beah-beaker-backend, ignoring: Invalid argument
Jan  2 14:11:59 ipaqavmd systemd: [/usr/lib/systemd/system/beah-srv.service:4] Failed to add dependency on beah-fwd-backend, ignoring: Invalid argument
Jan  2 14:11:59 ipaqavmd systemd: Stopping 389 Directory Server TESTRELM-COM....
Jan  2 14:12:00 ipaqavmd kernel: [  970.897796] ns-slapd[18289]: segfault at 10 ip 00007faf1e510bd1 sp 00007fff863cee28 error 4 in libpthread-2.17.so[7faf1e507000+16000]
Jan  2 14:12:00 ipaqavmd systemd: dirsrv: main process exited, code=killed, status=11/SEGV
Jan  2 14:12:00 ipaqavmd systemd: Unit dirsrv entered failed state.
Jan  2 14:12:00 ipaqavmd systemd: Starting 389 Directory Server TESTRELM-COM....


Additional info:

Possibly related to https://bugzilla.redhat.com/show_bug.cgi?id=987705, but that ticket had segfaults in libslapd.so.0.0.0

Comment 2 Noriko Hosoi 2014-01-02 20:02:10 UTC
Hi Michael,

Could there be a core file we could examine?

> ns-slapd[18289]: segfault at 10 ip 00007faf1e510bd1 sp 00007fff863cee28 error 4 in libpthread-2.17.so[7faf1e507000+16000]

Error 4 sounds odd to me since it is EINTR = "Interrupted system call"...  Could ns-slapd be killed by something else?

Comment 4 Noriko Hosoi 2014-01-07 22:51:33 UTC
Thanks, Michael, for the 4 core files!  All cores show the same crash point:

core.23364
(gdb) bt
#0  0x00007fa641135bd1 in pthread_mutex_destroy () from /lib64/libpthread.so.0
#1  0x00007fa64178c8f9 in PR_DestroyLock () from /lib64/libnspr4.so
#2  0x00007fa637a2314a in schedule_destroy (s=0x7fa6447d8ce0)
    at ldap/servers/plugins/replication/repl5_schedule.c:178
#3  0x00007fa637a04873 in agmt_delete (rap=0x7fa644549aa0)
    at ldap/servers/plugins/replication/repl5_agmt.c:633
#4  0x00007fa643193496 in object_release (o=0x7fa644549a90) at ldap/servers/slapd/object.c:113
#5  0x00007fa643193794 in objset_remove_obj (set=0x7fa64479df20, object=object@entry=0x7fa644549a90)
    at ldap/servers/slapd/objset.c:271
#6  0x00007fa637a08c59 in agmtlist_shutdown () at ldap/servers/plugins/replication/repl5_agmtlist.c:711
#7  0x00007fa637a0ff0f in multimaster_stop (pb=<optimized out>)
    at ldap/servers/plugins/replication/repl5_init.c:745
#8  0x00007fa64319ee45 in plugin_call_func (list=0x7fa64443e0a0, operation=210, pb=0x7fff53ebc5b0, 
    call_one=1) at ldap/servers/slapd/plugin.c:1453
#9  0x00007fa64319f0a3 in plugin_call_one (pb=<optimized out>, operation=<optimized out>, 
    list=<optimized out>) at ldap/servers/slapd/plugin.c:1421
#10 plugin_dependency_closeall () at ldap/servers/slapd/plugin.c:1365
#11 0x00007fa64319f0e7 in plugin_closeall (close_backends=close_backends@entry=1, 
    close_globals=close_globals@entry=1) at ldap/servers/slapd/plugin.c:1408
#12 0x00007fa643662567 in slapd_daemon (ports=ports@entry=0x7fff53ebcb40) at ldap/servers/slapd/daemon.c:1336
#13 0x00007fa6436556b5 in main (argc=7, argv=0x7fff53ebd158) at ldap/servers/slapd/main.c:1273

And the last 2 lines from error log:
>  
[07/Jan/2014:16:53:47 -0500] NSMMReplicationPlugin - agmt="cn=meToipaqa64vmd.testrelm.com" (ipaqa64vmd:389): Replication bind with GSSAPI auth resumed
[07/Jan/2014:17:04:32 -0500] NSMMReplicationPlugin - agmt_delete: begin

It turned out this is a duplicate of Bug 1049522 - Crash after replica is installed, which status is POST.

*** This bug has been marked as a duplicate of bug 1049522 ***