Bug 1434910 - replica install against IPA v3 master fails with ACIError
Summary: replica install against IPA v3 master fails with ACIError
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: ipa
Version: 7.4
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: ---
Assignee: IPA Maintainers
QA Contact: Nikhil Dehadrai
Depends On:
TreeView+ depends on / blocked
Reported: 2017-03-22 15:02 UTC by Tomas Krizek
Modified: 2017-08-01 09:46 UTC (History)
7 users (show)

Fixed In Version: ipa-4.5.0-3.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2017-08-01 09:46:16 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2304 normal SHIPPED_LIVE ipa bug fix and enhancement update 2017-08-01 12:41:35 UTC

Description Tomas Krizek 2017-03-22 15:02:17 UTC
This bug is created as a clone of upstream ticket:

When attempting to install a replica against an old (3.0.0) master, the installation fails when requesting keytab for DS:

    [26/44]: enabling SASL mapping fallback
      [27/44]: restarting directory server
      [28/44]: creating DS keytab
      [error] ACIError: Insufficient access: Insufficient 'add' privilege to add the entry 'krbprincipalname=ldap/replica2.ipa.test@IPA.TEST,cn=services,cn=accounts,dc=ipa,dc=test'.
    Your system may be partly configured.
    Run /usr/sbin/ipa-server-install --uninstall to clean up.

Traceback seen in ipareplica-install.log:

    File "/usr/lib/python2.7/site-packages/ipaserver/install/service.py", line 411, in run_step
      File "/usr/lib/python2.7/site-packages/ipaserver/install/dsinstance.py", line 1246, in _request_service_keytab
        super(DsInstance, self)._request_service_keytab()
      File "/usr/lib/python2.7/site-packages/ipaserver/install/service.py", line 581, in _request_service_keytab
      File "/usr/lib/python2.7/site-packages/ipaserver/install/service.py", line 537, in _add_service_principal
        self.api.Command.service_add(self.principal, force=True)
      File "/usr/lib/python2.7/site-packages/ipalib/frontend.py", line 447, in __call__
        return self.__do_call(*args, **options)
      File "/usr/lib/python2.7/site-packages/ipalib/frontend.py", line 475, in __do_call
        ret = self.run(*args, **options)
      File "/usr/lib/python2.7/site-packages/ipalib/frontend.py", line 798, in run
        return self.execute(*args, **options)
      File "/usr/lib/python2.7/site-packages/ipaserver/plugins/baseldap.py", line 1188, in execute
        self._exc_wrapper(keys, options, ldap.add_entry)(entry_attrs)
      File "/usr/lib/python2.7/site-packages/ipaserver/plugins/baseldap.py", line 1098, in wrapped
        return func(*call_args, **call_kwargs)
      File "/usr/lib/python2.7/site-packages/ipapython/ipaldap.py", line 1516, in add_entry
        self.conn.add_s(str(entry.dn), list(attrs.items()))
      File "/usr/lib64/python2.7/contextlib.py", line 35, in __exit__
        self.gen.throw(type, value, traceback)
      File "/usr/lib/python2.7/site-packages/ipapython/ipaldap.py", line 995, in error_handler
        raise errors.ACIError(info=info)

The root cause of this issue is probably caused by the fact that the remote connection in domain level 0 is created using host keytab of using Directory Manager password. Since ACIs permitting hosts to manage their own services were added in 4.2 release the old master denies this operations.

For this reason domain level 0 replica install should always use Directory manager credentials to create remote LDAP connection.

Comment 2 Tomas Krizek 2017-03-22 15:03:38 UTC
Upstream ticket:

Comment 9 Nikhil Dehadrai 2017-06-13 09:10:30 UTC
IPA_SERVER: ipa-server-3.0.0-51.el6.x86_64
IPA_REPLICA: ipa-server-4.5.0-16.el7.x86_64

Tested that the latest version of ipa-replica server can be configured against older version of IPA-Master(v3).

:: [ 11:40:06 ] :: RUN ipa-replica-prepare on ibm-x3250m4-12.rhts.eng.bos.redhat.com
:: [  BEGIN   ] :: Running 'ssh -o StrictHostKeyChecking=no root@ibm-x3250m4-12.rhts.eng.bos.redhat.com "echo Secret123|kinit admin; ipa-replica-prepare -p Secret123 --ip-address=10.x.x.x --reverse-zone=x.x.10.in-addr.arpa. intel-chiefriver-02.testrelm.test"'
Password for admin@TESTRELM.TEST: 
Preparing replica for intel-chiefriver-02.testrelm.test from ibm-x3250m4-12.testrelm.test
Creating SSL certificate for the Directory Server
Creating SSL certificate for the dogtag Directory Server
Creating SSL certificate for the Web Server
Exporting RA certificate
Copying additional files
Finalizing configuration
Packaging replica information into /var/lib/ipa/replica-info-intel-chiefriver-02.testrelm.test.gpg
Adding DNS records for intel-chiefriver-02.testrelm.test
Using reverse zone 186.16.10.in-addr.arpa.
:: [   PASS   ] :: Command 'ssh -o StrictHostKeyChecking=no root@ibm-x3250m4-12.rhts.eng.bos.redhat.com "echo Secret123|kinit admin; ipa-replica-prepare -p Secret123 --ip-address= --reverse-zone=186.16.10.in-addr.arpa. intel-chiefriver-02.testrelm.test"' (Expected 0, got 0)
:: [  BEGIN   ] :: Running 'ssh -o StrictHostKeyChecking=no root@ibm-x3250m4-12.rhts.eng.bos.redhat.com 'service named restart''
Stopping named: .[  OK  ]
Starting named: [  OK  ]
:: [   PASS   ] :: Command 'ssh -o StrictHostKeyChecking=no root@ibm-x3250m4-12.rhts.eng.bos.redhat.com 'service named restart'' (Expected 0, got 0)
:: [  BEGIN   ] :: Running 'sleep 60'
:: [   PASS   ] :: Command 'sleep 60' (Expected 0, got 0)
:: [ 11:41:20 ] :: RUN sftp to get gpg file
:: [  BEGIN   ] :: Running 'sftp -o StrictHostKeyChecking=no root@ibm-x3250m4-12.rhts.eng.bos.redhat.com:/var/lib/ipa/replica-info-intel-chiefriver-02.testrelm.test.gpg /opt/rhqa_ipa/'
Connected to ibm-x3250m4-12.rhts.eng.bos.redhat.com.
Fetching /var/lib/ipa/replica-info-intel-chiefriver-02.testrelm.test.gpg to /opt/rhqa_ipa/replica-info-intel-chiefriver-02.testrelm.test.gpg
:: [   PASS   ] :: Command 'sftp -o StrictHostKeyChecking=no root@ibm-x3250m4-12.rhts.eng.bos.redhat.com:/var/lib/ipa/replica-info-intel-chiefriver-02.testrelm.test.gpg /opt/rhqa_ipa/' (Expected 0, got 0)
:: [ 11:41:20 ] :: RUN ipa-replica-install
:: [  BEGIN   ] :: Running ' /usr/sbin/ipa-replica-install -U --setup-ca --setup-dns --forwarder=10.x.x.x -w Secret123 -p Secret123 /opt/rhqa_ipa/replica-info-intel-chiefriver-02.testrelm.test.gpg'
WARNING: No network interface matches the IP address 10.x.x.x
WARNING: conflicting time&date synchronization service 'chronyd' will
be disabled in favor of ntpd

Checking DNS forwarders, please wait ...
Run connection check to master
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: 30 seconds
  [1/40]: creating directory server instance
  [2/40]: enabling ldapi
  [3/40]: configure autobind for root
  [4/40]: stopping directory server
  [5/40]: updating configuration in dse.ldif
  [6/40]: starting directory server
  [7/40]: adding default schema
  [8/40]: enabling memberof plugin
  [9/40]: enabling winsync plugin
  [10/40]: configuring replication version plugin
  [11/40]: enabling IPA enrollment plugin
  [12/40]: configuring uniqueness plugin
  [13/40]: configuring uuid plugin
  [14/40]: configuring modrdn plugin
  [15/40]: configuring DNS plugin
  [16/40]: enabling entryUSN plugin
  [17/40]: configuring lockout plugin
  [18/40]: configuring topology plugin
  [19/40]: creating indices
  [20/40]: enabling referential integrity plugin
  [21/40]: configuring certmap.conf
  [22/40]: configure new location for managed entries
  [23/40]: configure dirsrv ccache
  [24/40]: enabling SASL mapping fallback
  [25/40]: restarting directory server
  [26/40]: creating DS keytab
  [27/40]: setting up initial replication
Starting replication, please wait until this has completed.

Update in progress, 1 seconds elapsed
Update in progress, 2 seconds elapsed
Update in progress, 3 seconds elapsed
Update succeeded

  [28/40]: adding sasl mappings to the directory
  [29/40]: updating schema
  [30/40]: setting Auto Member configuration
  [31/40]: enabling S4U2Proxy delegation
  [32/40]: initializing group membership
  [33/40]: adding master entry
  [34/40]: initializing domain level
  [35/40]: configuring Posix uid/gid generation
  [36/40]: adding replication acis
  [37/40]: activating sidgen plugin
  [38/40]: activating extdom plugin
  [39/40]: tuning directory server
  [40/40]: configuring directory to start on boot
Done configuring directory server (dirsrv).
Configuring Kerberos KDC (krb5kdc)
  [1/5]: configuring KDC
  [2/5]: adding the password extension to the directory
  [3/5]: creating anonymous principal
  [4/5]: starting the KDC
  [5/5]: 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 directory server (dirsrv)
  [1/3]: configuring TLS for DS instance
  [2/3]: importing CA certificates from LDAP
  [3/3]: restarting directory server
Done configuring directory server (dirsrv).
Configuring the web interface (httpd)
  [1/22]: stopping httpd
  [2/22]: setting mod_nss port to 443
  [3/22]: setting mod_nss cipher suite
  [4/22]: setting mod_nss protocol list to TLSv1.0 - TLSv1.2
  [5/22]: setting mod_nss password file
  [6/22]: enabling mod_nss renegotiate
  [7/22]: disabling mod_nss OCSP
  [8/22]: adding URL rewriting rules
  [9/22]: configuring httpd
  [10/22]: setting up httpd keytab
  [11/22]: configuring Gssproxy
  [12/22]: setting up ssl
  [13/22]: configure certmonger for renewals
  [14/22]: importing CA certificates from LDAP
  [15/22]: publish CA cert
  [16/22]: clean up any existing httpd ccaches
  [17/22]: configuring SELinux for httpd
  [18/22]: create KDC proxy config
  [19/22]: enable KDC proxy
  [20/22]: starting httpd
  [21/22]: configuring httpd to start on boot
  [22/22]: enabling oddjobd
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.
Configuring ipa-custodia
  [1/5]: Generating ipa-custodia config file
  [2/5]: Making sure custodia container exists
  [3/5]: Generating ipa-custodia keys
  [4/5]: starting ipa-custodia 
  [5/5]: configuring ipa-custodia to start on boot
Done configuring ipa-custodia.
Configuring certificate server (pki-tomcatd). Estimated time: 3 minutes
  [1/28]: configuring certificate server instance

MARK-LWD-LOOP -- 2017-06-12 11:42:22 --
  [2/28]: exporting Dogtag certificate store pin
  [3/28]: stopping certificate server instance to update CS.cfg
  [4/28]: backing up CS.cfg
  [5/28]: disabling nonces
  [6/28]: set up CRL publishing
  [7/28]: enable PKIX certificate path discovery and validation
  [8/28]: starting certificate server instance
  [9/28]: configure certmonger for renewals
  [10/28]: importing RA certificate from PKCS #12 file
  [11/28]: setting up signing cert profile
  [12/28]: setting audit signing renewal to 2 years
  [13/28]: restarting certificate server
  [14/28]: authorizing RA to modify profiles
  [15/28]: authorizing RA to manage lightweight CAs
  [16/28]: Ensure lightweight CAs container exists
  [17/28]: Ensuring backward compatibility
  [18/28]: configure certificate renewals
  [19/28]: configure Server-Cert certificate renewal
  [20/28]: Configure HTTP to proxy connections
  [21/28]: restarting certificate server
  [22/28]: updating IPA configuration
  [23/28]: enabling CA instance
  [24/28]: migrating certificate profiles to LDAP
  [25/28]: importing IPA certificate profiles
  [26/28]: adding default CA ACL
  [27/28]: adding 'ipa' CA entry
  [28/28]: configuring certmonger renewal for lightweight CAs
Done configuring certificate server (pki-tomcatd).
Applying LDAP updates
Upgrading IPA:. Estimated time: 1 minute 30 seconds
  [1/9]: stopping directory server
  [2/9]: saving configuration
  [3/9]: disabling listeners
  [4/9]: enabling DS global lock
  [5/9]: starting directory server
  [6/9]: upgrading server
  [7/9]: stopping directory server
  [8/9]: restoring configuration
  [9/9]: starting directory server
Restarting the KDC
Configuring DNS (named)
  [1/8]: generating rndc key file
  [2/8]: setting up our own record
  [3/8]: adding NS record to the zones
  [4/8]: setting up kerberos principal
  [5/8]: setting up named.conf
  [6/8]: setting up server configuration
  [7/8]: configuring named to start on boot
  [8/8]: changing resolv.conf to point to ourselves
Done configuring DNS (named).
Restarting the web server to pick up resolv.conf changes
Configuring DNS key synchronization service (ipa-dnskeysyncd)
  [1/7]: checking status
  [2/7]: setting up bind-dyndb-ldap working directory
  [3/7]: setting up kerberos principal
  [4/7]: setting up SoftHSM
  [5/7]: adding DNSSEC containers
  [6/7]: creating replica keys
  [7/7]: configuring ipa-dnskeysyncd to start on boot
Done configuring DNS key synchronization service (ipa-dnskeysyncd).
Restarting ipa-dnskeysyncd
Restarting named
Updating DNS system records

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

Configuring client side components
Using existing certificate '/etc/ipa/ca.crt'.
Client hostname: intel-chiefriver-02.testrelm.test
DNS Domain: testrelm.test
IPA Server: intel-chiefriver-02.testrelm.test
BaseDN: dc=testrelm,dc=test
Skipping synchronizing time with NTP server.
New SSSD config will be created
Configured sudoers in /etc/nsswitch.conf
Configured /etc/sssd/sssd.conf
trying https://intel-chiefriver-02.testrelm.test/ipa/json
[try 1]: Forwarding 'schema' to json server 'https://intel-chiefriver-02.testrelm.test/ipa/json'
trying https://intel-chiefriver-02.testrelm.test/ipa/session/json
[try 1]: Forwarding 'ping' to json server 'https://intel-chiefriver-02.testrelm.test/ipa/session/json'
[try 1]: Forwarding 'ca_is_enabled' to json server 'https://intel-chiefriver-02.testrelm.test/ipa/session/json'
Systemwide CA database updated.
Adding SSH public key from /etc/ssh/ssh_host_rsa_key.pub
Adding SSH public key from /etc/ssh/ssh_host_ecdsa_key.pub
Adding SSH public key from /etc/ssh/ssh_host_ed25519_key.pub
[try 1]: Forwarding 'host_mod' to json server 'https://intel-chiefriver-02.testrelm.test/ipa/session/json'
SSSD enabled
Configured /etc/openldap/ldap.conf
Configured /etc/ssh/ssh_config
Configured /etc/ssh/sshd_config
Configuring testrelm.test as NIS domain.
Client configuration complete.
The ipa-client-install command was successful

:: [   PASS   ] :: Command ' /usr/sbin/ipa-replica-install -U --setup-ca --setup-dns --forwarder=10.x.x.x -w Secret123 -p Secret123 /opt/rhqa_ipa/replica-info-intel-chiefriver-02.testrelm.test.gpg' (Expected 0, got 0)

Thus on the basis of above observation, marking status of bug to "VERIFIED".

Comment 10 errata-xmlrpc 2017-08-01 09:46:16 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, and where to find the updated
files, follow the link below.

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


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