Red Hat Bugzilla – Bug 748987
If master has leftover replica agreement from a previous failed attempt, next replica install can fail
Last modified: 2014-03-14 15:13:16 EDT
Description of problem: Created replica package on master, installed replica. But because of a bug in bind-dyndb-ldap, replica install failed when using setup-dns (bug 748901). So using same replica package, or after generating new package, replica install still failed when not using setup-dns (avoid this option to workaround bug 748901). This time with error that it "Failed to start replication" Had to run: ipa-replica-manage del ipa-replica.testrelm --force to delete/clean any replication agreement, and then was able to install successfully. Would be nice to have an error that specifically suggested to delete the replication agreement to be able to install successfully. ipareplica-install.log had: 2011-10-25 10:45:42,124 DEBUG stdout=Shutting down dirsrv: TESTRELM...^[[60G[^[[0;32m OK ^[[0;39m]^M Starting dirsrv: TESTRELM...^[[60G[^[[0;32m OK ^[[0;39m]^M 2011-10-25 10:45:42,124 DEBUG stderr= 2011-10-25 10:45:43,553 DEBUG Failed to start replication File "/usr/sbin/ipa-replica-install", line 482, in <module> main() File "/usr/sbin/ipa-replica-install", line 433, in main ds = install_replica_ds(config) File "/usr/sbin/ipa-replica-install", line 135, in install_replica_ds pkcs12_info) File "/usr/lib/python2.6/site-packages/ipaserver/install/dsinstance.py", line 284, in create_replica self.start_creation("Configuring directory server", 60) File "/usr/lib/python2.6/site-packages/ipaserver/install/service.py", line 248, in start_creation method() File "/usr/lib/python2.6/site-packages/ipaserver/install/dsinstance.py", line 297, in __setup_replica r_bindpw=self.dm_password) File "/usr/lib/python2.6/site-packages/ipaserver/install/replication.py", line 694, in setup_replication raise RuntimeError("Failed to start replication") Version-Release number of selected component (if applicable): ipa-server-2.1.3-3.el6.x86_64 How reproducible: if replica install failed in an attempt Steps to Reproduce: 1. on master, prepare replica package, then use it to install replica, where the install fails 2. now install replica again, where you know it should pass Actual results: fails with error - Failed to start replication Expected results: fail with error - delete replication agreement from master Additional info:
Upstream ticket: https://fedorahosted.org/freeipa/ticket/2030
Fixed upstream: master: https://fedorahosted.org/freeipa/changeset/4b539a41d9b562ed3372ea70fbb5d52c141a43f1 The issue can be also reproduced by installing a master and a replica, then uninstalling the replica and deleting the replica host entry. ipa-replica-install then returned me an error because a replication agreement existed. The new patch will detect this agreement and prompt user to delete it.
verified/automated [root@epsilon ipa-replica-install]# svn diff > ./diff.txt [root@epsilon ipa-replica-install]# cat diff.txt Index: t.replica-install.bug.sh =================================================================== --- t.replica-install.bug.sh (revision 4484) +++ t.replica-install.bug.sh (working copy) @@ -190,7 +190,7 @@ file=/dev/shm/bz823657-output.txt # Output file to be used in next tests rlRun "ipa-replica-manage del $SLAVE" 0 "Disconnect the slave agreement" rlRun "ipa-replica-manage connect $SLAVE $> $file" 0 "Reconnect the SLAVE." - rlRun "grep 'Unspecified GSS failure' $file" 2 "Ensure that a failure specified in BZ 82365 does not appear to be in teh output file $file" + rlRun "grep 'Unspecified GSS failure' $file" 1 "Ensure that a failure specified in BZ 823657 does not appear to be in the output file $file" rlPhaseEndTest } @@ -202,8 +202,8 @@ file=/dev/shm/bz824492-output.txt # Output file to be used in next tests rlRun "ipa-replica-manage disconnect $SLAVE" 0 "Disconnect the slave agreement" rlRun "ipa-replica-manage connect $SLAVE $> $file" 0 "Reconnect the SLAVE." - rlRun "grep 'You cannot connect to a previously deleted master' $file" 2 "Ensure that a failure specified in BZ 823567 does not appear to be in teh output file $file" - rlRun "grep 'list index out of range' $file" 2 "Ensure that a failure specified in BZ 823567 does not appear to be in teh output file $file" + rlRun "grep 'You cannot connect to a previously deleted master' $file" 1 "Ensure that a failure specified in BZ 824492 does not appear to be in the output file $file" + rlRun "grep 'list index out of range' $file" 1 "Ensure that a failure specified in BZ 824492 does not appear to be in the output file $file" rlPhaseEndTest }
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. http://rhn.redhat.com/errata/RHSA-2013-0528.html