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 1871064 - replica install failing during pki-ca component configuration
Summary: replica install failing during pki-ca component configuration
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: pki-core
Version: 8.3
Hardware: Unspecified
OS: Linux
urgent
urgent
Target Milestone: rc
: 8.0
Assignee: Alex Scheel
QA Contact: PKI QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-08-21 09:11 UTC by Kaleem
Modified: 2020-11-04 03:16 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-11-04 03:15:52 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2020:4847 0 None None None 2020-11-04 03:16:15 UTC

Description Kaleem 2020-08-21 09:11:46 UTC
Description of problem:

  [5/30]: configuring certificate server instance
Failed to configure CA instance: CalledProcessError(Command ['/usr/sbin/pkispawn', '-s', 'CA', '-f', '/tmp/tmpjj_x8so0'] returned non-zero exit status 1: 'Notice: Trust flag u is set automatically if the private key is present.\nWARNING: Unable to modify o=ipaca: netscape.ldap.LDAPException: error result (20); Type or value exists\nJob for pki-tomcatd failed because the control process exited with error code.\nSee "systemctl status pki-tomcatd" and "journalctl -xe" for details.\nERROR: CalledProcessError: Command \'[\'systemctl\', \'start\', \'pki-tomcatd\']\' returned non-zero exit status 1.\n  File "/usr/lib/python3.6/site-packages/pki/server/pkispawn.py", line 575, in main\n    scriptlet.spawn(deployer)\n  File "/usr/lib/python3.6/site-packages/pki/server/deployment/scriptlets/configuration.py", line 870, in spawn\n    instance.start()\n  File "/usr/lib/python3.6/site-packages/pki/server/__init__.py", line 261, in start\n    subprocess.check_call(cmd)\n  File "/usr/lib64/python3.6/subprocess.py", line 311, in check_call\n    raise CalledProcessError(retcode, cmd)\n\n')
See the installation logs and the following files/directories for more information:
  /var/log/pki/pki-tomcat
  [error] RuntimeError: CA configuration failed.
Your system may be partly configured.
Run /usr/sbin/ipa-server-install --uninstall to clean up.

CA configuration failed.
The ipa-replica-install command failed. See /var/log/ipareplica-install.log for more information

pki-ca-spawn log

[root@replica pki]# cat pki-ca-spawn.20200821050217.log 
2020-08-21 05:03:18 ERROR: CalledProcessError: Command '['systemctl', 'start', 'pki-tomcatd']' returned non-zero exit status 1.
  File "/usr/lib/python3.6/site-packages/pki/server/pkispawn.py", line 575, in main
    scriptlet.spawn(deployer)
  File "/usr/lib/python3.6/site-packages/pki/server/deployment/scriptlets/configuration.py", line 870, in spawn
    instance.start()
  File "/usr/lib/python3.6/site-packages/pki/server/__init__.py", line 261, in start
    subprocess.check_call(cmd)
  File "/usr/lib64/python3.6/subprocess.py", line 311, in check_call
    raise CalledProcessError(retcode, cmd)


Version-Release number of selected component (if applicable):
[root@replica ~]# rpm -q pki-ca ipa-server
pki-ca-10.9.2-1.module+el8.3.0+7691+db8f134f.noarch
ipa-server-4.8.7-10.module+el8.3.0+7702+ced5f219.x86_64
[root@replica ~]# 


How reproducible:
Always

Steps to Reproduce:
1. Instlall IPA replica 
2.
3.

Actual results:
Replica install failure 

Expected results:
no replica install failure 

Additional info:

Comment 5 Alex Scheel 2020-08-21 15:21:35 UTC
Checked in upstream:

commit 1753780b47c6935816d5419dafcea667fb01fed4
Author: Alexander Scheel <ascheel>
Date:   Fri Aug 21 10:15:53 2020 -0400

    Fix permissions when installing clone
    
    When pkispawn runs, it executes as root. However, rarely is PKI
    installed as root. The resulting permissions on ca.crt are 600,
    preventing later pki-server migrate command from running, as it
    runs as pkiuser, who doesn't have access to ca.crt. Fix the
    permissions when we initially create ca.crt to be owned by pkiuser.
    
    Signed-off-by: Alexander Scheel <ascheel>


Checked in dist-git:

commit a1d94e8c34e6ec86d2ef4aad12f791b9750e58f2
Author: Alexander Scheel <ascheel>
Date:   Fri Aug 21 11:20:21 2020 -0400

    Fix replica install failing during pki-ca component configuration
    
    Resolves: rhbz#1871064
    
    Signed-off-by: Alexander Scheel <ascheel>

Comment 11 shalini 2020-08-27 13:40:02 UTC
Cloning is validated in automated regression run. Following are the run links:

FIPS : https://gitlab.cee.redhat.com/idm/pki-pytest-ansible/-/jobs/2017915
Non FIPS : https://gitlab.cee.redhat.com/idm/pki-pytest-ansible/-/jobs/2017818


Validate on following versions:
 pki-ca                            noarch  10.9.2-2.module+el8.3.0+7729+bfb86605         RHEL8.3-Appstream  575 k
 pki-kra                           noarch  10.9.2-2.module+el8.3.0+7729+bfb86605         RHEL8.3-Appstream  200 k
 pki-ocsp noarch 10.9.2-1.module+el8pki+7692+b23293e3   RHEL8.3-CERTSYS    73 k
 pki-tks  noarch 10.9.2-1.module+el8pki+7692+b23293e3   RHEL8.3-CERTSYS   113 k
 pki-tps  x86_64 10.9.2-1.module+el8pki+7692+b23293e3   RHEL8.3-CERTSYS   680 k


Marking this BZ verified.

Comment 14 errata-xmlrpc 2020-11-04 03:15:52 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: pki-core:10.6 and pki-deps:10.6 security, bug fix, and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2020:4847


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