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 987705 - RHEL7 389-ds-base slapd segfault during ipa-replica-install
Summary: RHEL7 389-ds-base slapd segfault during ipa-replica-install
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: 389-ds-base
Version: 7.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Rich Megginson
QA Contact: Sankar Ramalingam
URL:
Whiteboard:
Depends On:
Blocks: 987767
TreeView+ depends on / blocked
 
Reported: 2013-07-23 23:40 UTC by Scott Poore
Modified: 2020-09-13 20:40 UTC (History)
6 users (show)

Fixed In Version: 389-ds-base-1.3.1.5-1.el7
Doc Type: Bug Fix
Doc Text:
Cause: The sorted array of values in each attribute was not being stored and cleaned up correctly during add/modify operations. This introduced a memory corruption. Consequence: The server would crash during certain add or modify operations. Fix: Ensure the sorted list of attributes is properly freed when being updated. Result: The server does not crash during certain add or modify operations.
Clone Of:
: 987767 1083272 (view as bug list)
Environment:
Last Closed: 2014-06-13 10:35:39 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
abrt crash dump dir from slapd segfault public version (26.06 KB, application/x-tar)
2013-07-24 01:36 UTC, Scott Poore
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github 389ds 389-ds-base issues 785 0 None None None 2020-09-13 20:40:00 UTC

Description Scott Poore 2013-07-23 23:40:42 UTC
Description of problem:

During ipa-replica-install, I'm seeing a segfault of slapd:

Jul 23 17:16:03 ipaqa64vmh kernel: [ 1909.707658] ns-slapd[18877]: segfault at 7f62cc003a10 ip 00007f5fd92c3693 sp 00007f5fa8ff45c0 error 4 in libslapd.so.0.0.0[7f5fd9203000+101000]

From Rich:

this looks like a crash in the new valueset code:

#0  0x00007f5fd92c3693 in valueset_find_sorted (a=0x7f5f6c0022a0,
     vs=vs@entry=0x7f5f6c0022d0, v=0x7f5f6c17f210,
     index=index@entry=0x7f5fa8ff461c) at ldap/servers/slapd/valueset.c:970
970            if ( (cmp = valueset_value_cmp(a, v,
vs->va[vs->sorted[mid]])) > 0)
(gdb) p vs->va
$1 = (struct slapi_value **) 0x7f5f6c003550
(gdb) p vs->va[0]
$2 = (struct slapi_value *) 0x7f5f6c17f050
(gdb) p vs->sorted
$3 = (int *) 0x7f5f6c17f360
(gdb) p mid
$4 = 0
(gdb) p vs->sorted[0]
$5 = 1811939480
(gdb) p *vs
$6 = {num = 1, max = 2, sorted = 0x7f5f6c17f360, va = 0x7f5f6c003550}
Version-Release number of selected component (if applicable):


How reproducible:
always

Steps to Reproduce:
1.  Install IPA Master server
2.  Install IPA Replica


Actual results:
fails at end of ipa-replica-install with:

Global DNS configuration in LDAP server is empty
You can use 'dnsconfig-mod' command to set global DNS options that
would override settings in local named.conf files

Restarting the web server

Your system may be partly configured.
Run /usr/sbin/ipa-server-install --uninstall to clean up.

/usr/sbin/ipa-replica-install -U --setup-ca --setup-dns --forwarder=<DNSFORWARDER> -w <PASSWD> -p <PASSWD> /opt/rhqa_ipa/replica-info-<servername>.testrelm.com.gpg' (Expected 0, got 1)

In /var/log/messages you'll see a segfault like above.

Expected results:

Installs with no segfaults or crashdumps.

Additional info:

Follow 389 Debug directions here to get core:

http://port389.org/wiki/FAQ#Debugging_Crashes

Comment 2 Rich Megginson 2013-07-23 23:44:56 UTC
This isn't from a customer - what private data could this contain that we can't share?

Comment 3 Scott Poore 2013-07-24 01:36:37 UTC
Created attachment 777540 [details]
abrt crash dump dir from slapd segfault public version

Attaching version of the abrt crash with some info scrubbed.  Unfortunately, this includes removed coredump file until I can confirm I am allowed to include it.  Hopefully, this helps make more of the problem public though.

Comment 5 Rich Megginson 2013-07-24 18:15:45 UTC
Upstream ticket:
https://fedorahosted.org/389/ticket/47448

Comment 6 Ján Rusnačko 2013-08-13 15:09:02 UTC
Is it possible to automate outside of FreeIPA ? If so, please add steps to reproduce.

Comment 7 Rich Megginson 2013-08-13 15:14:58 UTC
(In reply to Ján Rusnačko from comment #6)
> Is it possible to automate outside of FreeIPA ? If so, please add steps to
> reproduce.

r7772 | rmeggins | 2013-07-31 19:35:22 -0600 (Wed, 31 Jul 2013) | 3 l
ines

Added test for Ticket #47448 - Segfault in 389-ds-base-1.3.1.4-1.fc19 when setti
ng up FreeIPA

Comment 8 Scott Poore 2013-08-20 20:07:50 UTC
Verified for IPA:

Version ::

389-ds-base-1.3.1.6-1.el7.x86_64

Manual test results ::

[root@rhel7-8 yum.local.d]# ipa-replica-install -U --setup-ca --setup-dns --forwarder=$DNSFORWARD -w $ADMINPW -p $ADMINPW /dev/shm/replica-info-$SLAVE_S.$DOMAIN.gpg
Run connection check to master
Check connection from replica to remote master 'rhel7-7.testrelm.com':
   Directory Service: Unsecure port (389): OK
   Directory Service: Secure port (636): OK
   Kerberos KDC: TCP (88): OK
   Kerberos Kpasswd: TCP (464): OK
   HTTP Server: Unsecure port (80): OK
   HTTP Server: Secure port (443): OK

The following list of ports use UDP protocol and would need to be
checked manually:
   Kerberos KDC: UDP (88): SKIPPED
   Kerberos Kpasswd: UDP (464): SKIPPED

Connection from replica to master is OK.
Start listening on required ports for remote master check
Get credentials to log in to remote master
Check SSH connection to remote master
Execute check on remote master
Check connection from master to remote replica 'rhel7-8.testrelm.com':
   Directory Service: Unsecure port (389): OK
   Directory Service: Secure port (636): OK
   Kerberos KDC: TCP (88): OK
   Kerberos KDC: UDP (88): OK
   Kerberos Kpasswd: TCP (464): OK
   Kerberos Kpasswd: UDP (464): OK
   HTTP Server: Unsecure port (80): OK
   HTTP Server: Secure port (443): OK

Connection from master to replica is OK.

Connection check OK
Configuring NTP daemon (ntpd)
  [1/4]: stopping ntpd
  [2/4]: writing configuration
  [3/4]: configuring ntpd to start on boot
  [4/4]: starting ntpd
Done configuring NTP daemon (ntpd).
Configuring directory server (dirsrv): Estimated time 1 minute
  [1/33]: creating directory server user
  [2/33]: creating directory server instance
  [3/33]: adding default schema
  [4/33]: enabling memberof plugin
  [5/33]: enabling winsync plugin
  [6/33]: configuring replication version plugin
  [7/33]: enabling IPA enrollment plugin
  [8/33]: enabling ldapi
  [9/33]: configuring uniqueness plugin
  [10/33]: configuring uuid plugin
  [11/33]: configuring modrdn plugin
  [12/33]: configuring DNS plugin
  [13/33]: enabling entryUSN plugin
  [14/33]: configuring lockout plugin
  [15/33]: creating indices
  [16/33]: enabling referential integrity plugin
  [17/33]: configuring ssl for ds instance
  [18/33]: configuring certmap.conf
  [19/33]: configure autobind for root
  [20/33]: configure new location for managed entries
  [21/33]: configure dirsrv ccache
  [22/33]: enable SASL mapping fallback
  [23/33]: restarting directory server
  [24/33]: setting up initial replication
Starting replication, please wait until this has completed.
Update in progress, 7 seconds elapsed
Update succeeded

  [25/33]: setting Auto Member configuration
  [26/33]: enabling S4U2Proxy delegation
  [27/33]: initializing group membership
  [28/33]: adding master entry
  [29/33]: configuring Posix uid/gid generation
  [30/33]: adding replication acis
  [31/33]: enabling compatibility plugin
  [32/33]: tuning directory server
  [33/33]: configuring directory to start on boot
Done configuring directory server (dirsrv).
Configuring certificate server (pki-tomcatd): Estimated time 3 minutes 30 seconds
  [1/17]: creating certificate server user
  [2/17]: configuring certificate server instance
  [3/17]: disabling nonces
  [4/17]: creating RA agent certificate database
  [5/17]: importing CA chain to RA certificate database
  [6/17]: fixing RA database permissions
  [7/17]: setting up signing cert profile
  [8/17]: set up CRL publishing
  [9/17]: set certificate subject base
  [10/17]: enabling Subject Key Identifier
  [11/17]: enabling CRL and OCSP extensions for certificates
  [12/17]: setting audit signing renewal to 2 years
  [13/17]: configuring certificate server to start on boot
  [14/17]: configure certmonger for renewals
  [15/17]: configure clone certificate renewals
  [16/17]: configure Server-Cert certificate renewal
  [17/17]: Configure HTTP to proxy connections
Done configuring certificate server (pki-tomcatd).
Restarting the directory and certificate servers
Configuring Kerberos KDC (krb5kdc): Estimated time 30 seconds
  [1/9]: adding sasl mappings to the directory
  [2/9]: writing stash file from DS
  [3/9]: configuring KDC
  [4/9]: creating a keytab for the directory
  [5/9]: creating a keytab for the machine
  [6/9]: adding the password extension to the directory
  [7/9]: enable GSSAPI for replication
  [8/9]: starting the KDC
  [9/9]: configuring KDC to start on boot
Done configuring Kerberos KDC (krb5kdc).
Configuring kadmin
  [1/2]: starting kadmin 
  [2/2]: configuring kadmin to start on boot
Done configuring kadmin.
Configuring ipa_memcached
  [1/2]: starting ipa_memcached 
  [2/2]: configuring ipa_memcached to start on boot
Done configuring ipa_memcached.
Configuring the web interface (httpd): Estimated time 1 minute
  [1/14]: disabling mod_ssl in httpd
  [2/14]: setting mod_nss port to 443
  [3/14]: setting mod_nss password file
  [4/14]: enabling mod_nss renegotiate
  [5/14]: adding URL rewriting rules
  [6/14]: configuring httpd
  [7/14]: setting up ssl
  [8/14]: publish CA cert
  [9/14]: creating a keytab for httpd
  [10/14]: clean up any existing httpd ccache
  [11/14]: configuring SELinux for httpd
  [12/14]: configure httpd ccache
  [13/14]: restarting httpd
  [14/14]: configuring httpd to start on boot
Done configuring the web interface (httpd).
Configuring ipa-otpd
  [1/2]: starting ipa-otpd 
  [2/2]: configuring ipa-otpd to start on boot
Done configuring ipa-otpd.
Applying LDAP updates
Restarting the directory server
Restarting the KDC
Using reverse zone 122.168.192.in-addr.arpa.
Configuring DNS (named)
  [1/9]: adding NS record to the zone
  [2/9]: setting up reverse zone
  [3/9]: setting up our own record
  [4/9]: setting up CA record
  [5/9]: setting up kerberos principal
  [6/9]: setting up named.conf
  [7/9]: restarting named
  [8/9]: configuring named to start on boot
  [9/9]: changing resolv.conf to point to ourselves
Done configuring DNS (named).

Global DNS configuration in LDAP server is empty
You can use 'dnsconfig-mod' command to set global DNS options that
would override settings in local named.conf files

Restarting the web server

[root@rhel7-8 yum.local.d]# grep -i "Could not connect to the Directory Server" /var/log/ipareplica-install.log

[root@rhel7-8 yum.local.d]# grep -i "ns-slapd.*segfault" /var/log/messages 
[root@rhel7-8 yum.local.d]#

Comment 9 Rich Megginson 2013-10-01 23:23:58 UTC
moving all ON_QA bugs to MODIFIED in order to add them to the errata (can't add bugs in the ON_QA state to an errata).  When the errata is created, the bugs should be automatically moved back to ON_QA.

Comment 11 Jenny Severance 2013-11-11 16:40:05 UTC
Based on comment #8 marking VERIFIED

Comment 12 Ludek Smid 2014-06-13 10:35:39 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.


Note You need to log in before you can comment on or make changes to this bug.