The repl-monitor.pl script has this loop in print_consumers
print_consumers
# Collect all the consumer replicas for the current master replica push (@consumers, $m_ridx); foreach (@consumers) { $s_ridx = $_; for (@allagreements) { next if ($_->{ridx} != $s_ridx); $c_ridx = $_->{cidx}; next if $c_ridx == $m_ridx; push @ouragreements, $_; $found = 0; foreach (@consumers) { if ($_ == $c_ridx) { $found = 1; last; } } push (@consumers, $c_ridx) if !$found; } }
The problem is that it modifies the @consumers array within the loop producing unpredictable results. At the time of my testing, @consumers would include consumers that were not actually consumers of a given master. I believe it's sufficient to change it to:
@consumers
# Collect all the consumer replicas for the current master replica $s_ridx = $m_ridx; for (@allagreements) { next if ($_->{ridx} != $s_ridx); $c_ridx = $_->{cidx}; next if $c_ridx == $m_ridx; push @ouragreements, $_; printf "s_ridx=%s. Pushing to agreements: ridx=%s\n", $s_ridx, $_->{ridx}; $found = 0; foreach (@consumers) { if ($_ == $c_ridx) { $found = 1; last; } } push (@consumers, $c_ridx) if !$found; }
It has been some time since I carefully considered the logic but at the time of my analysis, that was the conclusion I came to.
389-ds-base-1.3.5.10-21.el7_3.x86_64
1. 2. 3.
Metadata Update from @mreynolds: - Custom field component adjusted to None - Custom field origin adjusted to None - Custom field reviewstatus adjusted to None - Custom field type adjusted to None - Custom field version adjusted to None - Issue set to the milestone: 1.4.0
The issue is rarely leads to any errors and it's more of a cleanup issue. Anyway, this perl script is going to be deprecated. We have the replacement script dsconf replication monitor which doesn't have the issue. Closing as won't fix.
dsconf replication monitor
Metadata Update from @spichugi: - Issue close_status updated to: wontfix - Issue status updated to: Closed (was: Open)
389-ds-base is moving from Pagure to Github. This means that new issues and pull requests will be accepted only in 389-ds-base's github repository.
This issue has been cloned to Github and is available here: - https://github.com/389ds/389-ds-base/issues/2499
If you want to receive further updates on the issue, please navigate to the github issue and click on subscribe button.
subscribe
Thank you for understanding. We apologize for all inconvenience.
Login to comment on this ticket.