Blame SOURCES/0022-Issue-4656-remove-problematic-language-from-ds-replc.patch

e4a41f
From d2ac7e98d53cfe6c74c99ddf3504b1072418f05a Mon Sep 17 00:00:00 2001
e4a41f
From: Mark Reynolds <mreynolds@redhat.com>
e4a41f
Date: Thu, 11 Mar 2021 10:12:46 -0500
e4a41f
Subject: [PATCH] Issue 4656 - remove problematic language from ds-replcheck
e4a41f
e4a41f
Description: remove master from ds-replcheck and replace it with supplier
e4a41f
e4a41f
relates: https://github.com/389ds/389-ds-base/issues/4656
e4a41f
e4a41f
Reviewed by: mreynolds
e4a41f
e4a41f
e with '#' will be ignored, and an empty message aborts the commit.
e4a41f
---
e4a41f
 ldap/admin/src/scripts/ds-replcheck | 202 ++++++++++++++--------------
e4a41f
 1 file changed, 101 insertions(+), 101 deletions(-)
e4a41f
e4a41f
diff --git a/ldap/admin/src/scripts/ds-replcheck b/ldap/admin/src/scripts/ds-replcheck
e4a41f
index 169496e8f..f411f357a 100755
e4a41f
--- a/ldap/admin/src/scripts/ds-replcheck
e4a41f
+++ b/ldap/admin/src/scripts/ds-replcheck
e4a41f
@@ -1,7 +1,7 @@
e4a41f
 #!/usr/bin/python3
e4a41f
 
e4a41f
 # --- BEGIN COPYRIGHT BLOCK ---
e4a41f
-# Copyright (C) 2020 Red Hat, Inc.
e4a41f
+# Copyright (C) 2021 Red Hat, Inc.
e4a41f
 # All rights reserved.
e4a41f
 #
e4a41f
 # License: GPL (version 3 or any later version).
e4a41f
@@ -63,7 +63,7 @@ def remove_entry(rentries, dn):
e4a41f
 def get_ruv_time(ruv, rid):
e4a41f
     """Take a RUV element (nsds50ruv attribute) and extract the timestamp from maxcsn
e4a41f
     :param ruv - A lsit of RUV elements
e4a41f
-    :param rid - The rid of the master to extractthe maxcsn time from
e4a41f
+    :param rid - The rid of the supplier to extract the maxcsn time from
e4a41f
     :return: The time in seconds of the maxcsn, or 0 if there is no maxcsn, or -1 if
e4a41f
              the rid was not found
e4a41f
     """
e4a41f
@@ -213,22 +213,22 @@ def get_ruv_state(opts):
e4a41f
     :param opts - all the script options
e4a41f
     :return - A text description of the replicaton state
e4a41f
     """
e4a41f
-    mtime = get_ruv_time(opts['master_ruv'], opts['rid'])
e4a41f
+    mtime = get_ruv_time(opts['supplier_ruv'], opts['rid'])
e4a41f
     rtime = get_ruv_time(opts['replica_ruv'], opts['rid'])
e4a41f
     if mtime == -1:
e4a41f
-        repl_state = "Replication State: Replica ID ({}) not found in Master's RUV".format(opts['rid'])
e4a41f
+        repl_state = "Replication State: Replica ID ({}) not found in Supplier's RUV".format(opts['rid'])
e4a41f
     elif rtime == -1:
e4a41f
         repl_state = "Replication State: Replica ID ({}) not found in Replica's RUV (not initialized?)".format(opts['rid'])
e4a41f
     elif mtime == 0:
e4a41f
-        repl_state = "Replication State: Master has not seen any updates"
e4a41f
+        repl_state = "Replication State: Supplier has not seen any updates"
e4a41f
     elif rtime == 0:
e4a41f
-        repl_state = "Replication State: Replica has not seen any changes from the Master"
e4a41f
+        repl_state = "Replication State: Replica has not seen any changes from the Supplier"
e4a41f
     elif mtime > rtime:
e4a41f
-        repl_state = "Replication State: Replica is behind Master by: {} seconds".format(mtime - rtime)
e4a41f
+        repl_state = "Replication State: Replica is behind Supplier by: {} seconds".format(mtime - rtime)
e4a41f
     elif mtime < rtime:
e4a41f
-        repl_state = "Replication State: Replica is ahead of Master by: {} seconds".format(rtime - mtime)
e4a41f
+        repl_state = "Replication State: Replica is ahead of Supplier by: {} seconds".format(rtime - mtime)
e4a41f
     else:
e4a41f
-        repl_state = "Replication State: Master and Replica are in perfect synchronization"
e4a41f
+        repl_state = "Replication State: Supplier and Replica are in perfect synchronization"
e4a41f
 
e4a41f
     return repl_state
e4a41f
 
e4a41f
@@ -238,11 +238,11 @@ def get_ruv_report(opts):
e4a41f
     :param opts - all the script options
e4a41f
     :return - A text blob to display in the report
e4a41f
     """
e4a41f
-    opts['master_ruv'].sort()
e4a41f
+    opts['supplier_ruv'].sort()
e4a41f
     opts['replica_ruv'].sort()
e4a41f
 
e4a41f
-    report = "Master RUV:\n"
e4a41f
-    for element in opts['master_ruv']:
e4a41f
+    report = "Supplier RUV:\n"
e4a41f
+    for element in opts['supplier_ruv']:
e4a41f
         report += "  %s\n" % (element)
e4a41f
     report += "\nReplica RUV:\n"
e4a41f
     for element in opts['replica_ruv']:
e4a41f
@@ -521,7 +521,7 @@ def get_ldif_ruv(LDIF, opts):
e4a41f
 
e4a41f
 def cmp_entry(mentry, rentry, opts):
e4a41f
     """Compare the two entries, and return a "diff map"
e4a41f
-    :param mentry - A Master entry
e4a41f
+    :param mentry - A Supplier entry
e4a41f
     :param rentry - A Replica entry
e4a41f
     :param opts - A Dict of the scripts options
e4a41f
     :return - A Dict of the differences in the entry, or None
e4a41f
@@ -536,7 +536,7 @@ def cmp_entry(mentry, rentry, opts):
e4a41f
     mlist = list(mentry.data.keys())
e4a41f
 
e4a41f
     #
e4a41f
-    # Check master
e4a41f
+    # Check Supplier
e4a41f
     #
e4a41f
     for mattr in mlist:
e4a41f
         if mattr in opts['ignore']:
e4a41f
@@ -555,7 +555,7 @@ def cmp_entry(mentry, rentry, opts):
e4a41f
                             if not found:
e4a41f
                                 diff['missing'].append("")
e4a41f
                             found = True
e4a41f
-                            diff['missing'].append(" - Master's State Info: %s" % (val))
e4a41f
+                            diff['missing'].append(" - Supplier's State Info: %s" % (val))
e4a41f
                             diff['missing'].append(" - Date: %s\n" % (time.ctime(extract_time(val))))
e4a41f
                 else:
e4a41f
                     # No state info, just move on
e4a41f
@@ -566,18 +566,18 @@ def cmp_entry(mentry, rentry, opts):
e4a41f
             if report_conflict(rentry, mattr, opts) and report_conflict(mentry, mattr, opts):
e4a41f
                 diff['diff'].append(" - Attribute '%s' is different:" % mattr)
e4a41f
                 if 'nscpentrywsi' in mentry.data:
e4a41f
-                    # Process Master
e4a41f
+                    # Process Supplier
e4a41f
                     found = False
e4a41f
                     for val in mentry.data['nscpentrywsi']:
e4a41f
                         if val.lower().startswith(mattr + ';'):
e4a41f
                             if not found:
e4a41f
-                                diff['diff'].append("      Master:")
e4a41f
+                                diff['diff'].append("      Supplier:")
e4a41f
                             diff['diff'].append("        - Value:      %s" % (val.split(':')[1].lstrip()))
e4a41f
                             diff['diff'].append("        - State Info: %s" % (val))
e4a41f
                             diff['diff'].append("        - Date:       %s\n" % (time.ctime(extract_time(val))))
e4a41f
                             found = True
e4a41f
                     if not found:
e4a41f
-                        diff['diff'].append("      Master: ")
e4a41f
+                        diff['diff'].append("      Supplier: ")
e4a41f
                         for val in mentry.data[mattr]:
e4a41f
                             # This is an "origin" value which means it's never been
e4a41f
                             # updated since replication was set up.  So its the
e4a41f
@@ -605,7 +605,7 @@ def cmp_entry(mentry, rentry, opts):
e4a41f
                         diff['diff'].append("")
e4a41f
                 else:
e4a41f
                     # no state info, report what we got
e4a41f
-                    diff['diff'].append("      Master: ")
e4a41f
+                    diff['diff'].append("      Supplier: ")
e4a41f
                     for val in mentry.data[mattr]:
e4a41f
                         diff['diff'].append("        - %s: %s" % (mattr, val))
e4a41f
                     diff['diff'].append("      Replica: ")
e4a41f
@@ -622,9 +622,9 @@ def cmp_entry(mentry, rentry, opts):
e4a41f
             continue
e4a41f
 
e4a41f
         if rattr not in mlist:
e4a41f
-            # Master is missing the attribute
e4a41f
+            # Supplier is missing the attribute
e4a41f
             if report_conflict(rentry, rattr, opts):
e4a41f
-                diff['missing'].append(" - Master missing attribute: \"%s\"" % (rattr))
e4a41f
+                diff['missing'].append(" - Supplier missing attribute: \"%s\"" % (rattr))
e4a41f
                 diff_count += 1
e4a41f
                 if 'nscpentrywsi' in rentry.data:
e4a41f
                     found = False
e4a41f
@@ -663,7 +663,7 @@ def do_offline_report(opts, output_file=None):
e4a41f
     try:
e4a41f
         MLDIF = open(opts['mldif'], "r")
e4a41f
     except Exception as e:
e4a41f
-        print('Failed to open Master LDIF: ' + str(e))
e4a41f
+        print('Failed to open Supplier LDIF: ' + str(e))
e4a41f
         return
e4a41f
 
e4a41f
     try:
e4a41f
@@ -676,10 +676,10 @@ def do_offline_report(opts, output_file=None):
e4a41f
     # Verify LDIF Files
e4a41f
     try:
e4a41f
         if opts['verbose']:
e4a41f
-            print("Validating Master ldif file ({})...".format(opts['mldif']))
e4a41f
+            print("Validating Supplier ldif file ({})...".format(opts['mldif']))
e4a41f
         LDIFRecordList(MLDIF).parse()
e4a41f
     except ValueError:
e4a41f
-        print('Master LDIF file in invalid, aborting...')
e4a41f
+        print('Supplier LDIF file in invalid, aborting...')
e4a41f
         MLDIF.close()
e4a41f
         RLDIF.close()
e4a41f
         return
e4a41f
@@ -696,34 +696,34 @@ def do_offline_report(opts, output_file=None):
e4a41f
     # Get all the dn's, and entry counts
e4a41f
     if opts['verbose']:
e4a41f
         print ("Gathering all the DN's...")
e4a41f
-    master_dns = get_dns(MLDIF, opts['mldif'], opts)
e4a41f
+    supplier_dns = get_dns(MLDIF, opts['mldif'], opts)
e4a41f
     replica_dns = get_dns(RLDIF, opts['rldif'], opts)
e4a41f
-    if master_dns is None or replica_dns is None:
e4a41f
+    if supplier_dns is None or replica_dns is None:
e4a41f
         print("Aborting scan...")
e4a41f
         MLDIF.close()
e4a41f
         RLDIF.close()
e4a41f
         sys.exit(1)
e4a41f
-    m_count = len(master_dns)
e4a41f
+    m_count = len(supplier_dns)
e4a41f
     r_count = len(replica_dns)
e4a41f
 
e4a41f
     # Get DB RUV
e4a41f
     if opts['verbose']:
e4a41f
         print ("Gathering the database RUV's...")
e4a41f
-    opts['master_ruv'] = get_ldif_ruv(MLDIF, opts)
e4a41f
+    opts['supplier_ruv'] = get_ldif_ruv(MLDIF, opts)
e4a41f
     opts['replica_ruv'] = get_ldif_ruv(RLDIF, opts)
e4a41f
 
e4a41f
-    """ Compare the master entries with the replica's.  Take our list of dn's from
e4a41f
-    the master ldif and get that entry( dn) from the master and replica ldif.  In
e4a41f
+    """ Compare the Supplier entries with the replica's.  Take our list of dn's from
e4a41f
+    the Supplier ldif and get that entry( dn) from the Supplier and replica ldif.  In
e4a41f
     this phase we keep keep track of conflict/tombstone counts, and we check for
e4a41f
     missing entries and entry differences.   We only need to do the entry diff
e4a41f
     checking in this phase - we do not need to do it when process the replica dn's
e4a41f
     because if the entry exists in both LDIF's then we already checked or diffs
e4a41f
-    while processing the master dn's.
e4a41f
+    while processing the Supplier dn's.
e4a41f
     """
e4a41f
     if opts['verbose']:
e4a41f
-        print ("Comparing Master to Replica...")
e4a41f
+        print ("Comparing Supplier to Replica...")
e4a41f
     missing = False
e4a41f
-    for dn in master_dns:
e4a41f
+    for dn in supplier_dns:
e4a41f
         mresult = ldif_search(MLDIF, dn)
e4a41f
         if mresult['entry'] is None and mresult['conflict'] is None and not mresult['tombstone']:
e4a41f
             # Try from the beginning
e4a41f
@@ -736,7 +736,7 @@ def do_offline_report(opts, output_file=None):
e4a41f
                 rresult['conflict'] is not None or rresult['tombstone']):
e4a41f
                 """ We can safely remove this DN from the replica dn list as it
e4a41f
                 does not need to be checked again.  This also speeds things up
e4a41f
-                when doing the replica vs master phase.
e4a41f
+                when doing the replica vs Supplier phase.
e4a41f
                 """
e4a41f
                 replica_dns.remove(dn)
e4a41f
 
e4a41f
@@ -766,7 +766,7 @@ def do_offline_report(opts, output_file=None):
e4a41f
                         missing_report += ('  Entries missing on Replica:\n')
e4a41f
                         missing = True
e4a41f
                     if mresult['entry'] and 'createtimestamp' in mresult['entry'].data:
e4a41f
-                        missing_report += ('   - %s  (Created on Master at: %s)\n' %
e4a41f
+                        missing_report += ('   - %s  (Created on Supplier at: %s)\n' %
e4a41f
                                            (dn, convert_timestamp(mresult['entry'].data['createtimestamp'][0])))
e4a41f
                     else:
e4a41f
                         missing_report += ('  - %s\n' % dn)
e4a41f
@@ -791,7 +791,7 @@ def do_offline_report(opts, output_file=None):
e4a41f
     remaining conflict & tombstone entries as well.
e4a41f
     """
e4a41f
     if opts['verbose']:
e4a41f
-        print ("Comparing Replica to Master...")
e4a41f
+        print ("Comparing Replica to Supplier...")
e4a41f
     MLDIF.seek(0)
e4a41f
     RLDIF.seek(0)
e4a41f
     missing = False
e4a41f
@@ -811,7 +811,7 @@ def do_offline_report(opts, output_file=None):
e4a41f
             if mresult['entry'] is None and mresult['glue'] is None:
e4a41f
                 MLDIF.seek(rresult['idx'])  # Set the LDIF cursor/index to the last good line
e4a41f
                 if not missing:
e4a41f
-                    missing_report += ('  Entries missing on Master:\n')
e4a41f
+                    missing_report += ('  Entries missing on Supplier:\n')
e4a41f
                     missing = True
e4a41f
                 if rresult['entry'] and 'createtimestamp' in rresult['entry'].data:
e4a41f
                     missing_report += ('   - %s  (Created on Replica at: %s)\n' %
e4a41f
@@ -837,12 +837,12 @@ def do_offline_report(opts, output_file=None):
e4a41f
     final_report += get_ruv_report(opts)
e4a41f
     final_report += ('Entry Counts\n')
e4a41f
     final_report += ('=====================================================\n\n')
e4a41f
-    final_report += ('Master:  %d\n' % (m_count))
e4a41f
+    final_report += ('Supplier:  %d\n' % (m_count))
e4a41f
     final_report += ('Replica: %d\n\n' % (r_count))
e4a41f
 
e4a41f
     final_report += ('\nTombstones\n')
e4a41f
     final_report += ('=====================================================\n\n')
e4a41f
-    final_report += ('Master:  %d\n' % (mtombstones))
e4a41f
+    final_report += ('Supplier:  %d\n' % (mtombstones))
e4a41f
     final_report += ('Replica: %d\n' % (rtombstones))
e4a41f
 
e4a41f
     final_report += get_conflict_report(mconflicts, rconflicts, opts['conflicts'])
e4a41f
@@ -859,9 +859,9 @@ def do_offline_report(opts, output_file=None):
e4a41f
     final_report += ('\nResult\n')
e4a41f
     final_report += ('=====================================================\n\n')
e4a41f
     if missing_report == "" and len(diff_report) == 0:
e4a41f
-        final_report += ('No replication differences between Master and Replica\n')
e4a41f
+        final_report += ('No replication differences between Supplier and Replica\n')
e4a41f
     else:
e4a41f
-        final_report += ('There are replication differences between Master and Replica\n')
e4a41f
+        final_report += ('There are replication differences between Supplier and Replica\n')
e4a41f
 
e4a41f
     if output_file:
e4a41f
         output_file.write(final_report)
e4a41f
@@ -871,8 +871,8 @@ def do_offline_report(opts, output_file=None):
e4a41f
 
e4a41f
 def check_for_diffs(mentries, mglue, rentries, rglue, report, opts):
e4a41f
     """Online mode only - Check for diffs, return the updated report
e4a41f
-    :param mentries - Master entries
e4a41f
-    :param mglue - Master glue entries
e4a41f
+    :param mentries - Supplier entries
e4a41f
+    :param mglue - Supplier glue entries
e4a41f
     :param rentries - Replica entries
e4a41f
     :param rglue - Replica glue entries
e4a41f
     :param report - A Dict of the entire report
e4a41f
@@ -947,8 +947,8 @@ def validate_suffix(ldapnode, suffix, hostname):
e4a41f
     # Check suffix is replicated
e4a41f
     try:
e4a41f
         replica_filter = "(&(objectclass=nsds5replica)(nsDS5ReplicaRoot=%s))" % suffix
e4a41f
-        master_replica = ldapnode.search_s("cn=config",ldap.SCOPE_SUBTREE,replica_filter)
e4a41f
-        if (len(master_replica) != 1):
e4a41f
+        supplier_replica = ldapnode.search_s("cn=config",ldap.SCOPE_SUBTREE,replica_filter)
e4a41f
+        if (len(supplier_replica) != 1):
e4a41f
             print("Error: Failed to validate suffix in {}. {} is not replicated.".format(hostname, suffix))
e4a41f
             return False
e4a41f
     except ldap.LDAPError as e:
e4a41f
@@ -969,7 +969,7 @@ def connect_to_replicas(opts):
e4a41f
         muri = "%s://%s" % (opts['mprotocol'], opts['mhost'].replace("/", "%2f"))
e4a41f
     else:
e4a41f
         muri = "%s://%s:%s/" % (opts['mprotocol'], opts['mhost'], opts['mport'])
e4a41f
-    master = SimpleLDAPObject(muri)
e4a41f
+    supplier = SimpleLDAPObject(muri)
e4a41f
 
e4a41f
     if opts['rprotocol'].lower() == 'ldapi':
e4a41f
         ruri = "%s://%s" % (opts['rprotocol'], opts['rhost'].replace("/", "%2f"))
e4a41f
@@ -978,23 +978,23 @@ def connect_to_replicas(opts):
e4a41f
     replica = SimpleLDAPObject(ruri)
e4a41f
 
e4a41f
     # Set timeouts
e4a41f
-    master.set_option(ldap.OPT_NETWORK_TIMEOUT, opts['timeout'])
e4a41f
-    master.set_option(ldap.OPT_TIMEOUT, opts['timeout'])
e4a41f
+    supplier.set_option(ldap.OPT_NETWORK_TIMEOUT, opts['timeout'])
e4a41f
+    supplier.set_option(ldap.OPT_TIMEOUT, opts['timeout'])
e4a41f
     replica.set_option(ldap.OPT_NETWORK_TIMEOUT, opts['timeout'])
e4a41f
     replica.set_option(ldap.OPT_TIMEOUT, opts['timeout'])
e4a41f
 
e4a41f
     # Setup Secure Connection
e4a41f
     if opts['certdir'] is not None:
e4a41f
-        # Setup Master
e4a41f
+        # Setup Supplier
e4a41f
         if opts['mprotocol'] != LDAPI:
e4a41f
-            master.set_option(ldap.OPT_X_TLS_CACERTDIR, opts['certdir'])
e4a41f
-            master.set_option(ldap.OPT_X_TLS_REQUIRE_CERT, ldap.OPT_X_TLS_HARD)
e4a41f
+            supplier.set_option(ldap.OPT_X_TLS_CACERTDIR, opts['certdir'])
e4a41f
+            supplier.set_option(ldap.OPT_X_TLS_REQUIRE_CERT, ldap.OPT_X_TLS_HARD)
e4a41f
             if opts['mprotocol'] == LDAP:
e4a41f
                 # Do StartTLS
e4a41f
                 try:
e4a41f
-                    master.start_tls_s()
e4a41f
+                    supplier.start_tls_s()
e4a41f
                 except ldap.LDAPError as e:
e4a41f
-                    print('TLS negotiation failed on Master: {}'.format(str(e)))
e4a41f
+                    print('TLS negotiation failed on Supplier: {}'.format(str(e)))
e4a41f
                     exit(1)
e4a41f
 
e4a41f
         # Setup Replica
e4a41f
@@ -1006,17 +1006,17 @@ def connect_to_replicas(opts):
e4a41f
                 try:
e4a41f
                     replica.start_tls_s()
e4a41f
                 except ldap.LDAPError as e:
e4a41f
-                    print('TLS negotiation failed on Master: {}'.format(str(e)))
e4a41f
+                    print('TLS negotiation failed on Supplier: {}'.format(str(e)))
e4a41f
                     exit(1)
e4a41f
 
e4a41f
-    # Open connection to master
e4a41f
+    # Open connection to Supplier
e4a41f
     try:
e4a41f
-        master.simple_bind_s(opts['binddn'], opts['bindpw'])
e4a41f
+        supplier.simple_bind_s(opts['binddn'], opts['bindpw'])
e4a41f
     except ldap.SERVER_DOWN as e:
e4a41f
         print(f"Cannot connect to {muri} ({str(e)})")
e4a41f
         sys.exit(1)
e4a41f
     except ldap.LDAPError as e:
e4a41f
-        print("Error: Failed to authenticate to Master: ({}).  "
e4a41f
+        print("Error: Failed to authenticate to Supplier: ({}).  "
e4a41f
               "Please check your credentials and LDAP urls are correct.".format(str(e)))
e4a41f
         sys.exit(1)
e4a41f
 
e4a41f
@@ -1034,7 +1034,7 @@ def connect_to_replicas(opts):
e4a41f
     # Validate suffix
e4a41f
     if opts['verbose']:
e4a41f
         print ("Validating suffix ...")
e4a41f
-    if not validate_suffix(master, opts['suffix'], opts['mhost']):
e4a41f
+    if not validate_suffix(supplier, opts['suffix'], opts['mhost']):
e4a41f
       sys.exit(1)
e4a41f
 
e4a41f
     if not validate_suffix(replica,opts['suffix'], opts['rhost']):
e4a41f
@@ -1042,16 +1042,16 @@ def connect_to_replicas(opts):
e4a41f
 
e4a41f
     # Get the RUVs
e4a41f
     if opts['verbose']:
e4a41f
-        print ("Gathering Master's RUV...")
e4a41f
+        print ("Gathering Supplier's RUV...")
e4a41f
     try:
e4a41f
-        master_ruv = master.search_s(opts['suffix'], ldap.SCOPE_SUBTREE, RUV_FILTER, ['nsds50ruv'])
e4a41f
-        if len(master_ruv) > 0:
e4a41f
-            opts['master_ruv'] = ensure_list_str(master_ruv[0][1]['nsds50ruv'])
e4a41f
+        supplier_ruv = supplier.search_s(opts['suffix'], ldap.SCOPE_SUBTREE, RUV_FILTER, ['nsds50ruv'])
e4a41f
+        if len(supplier_ruv) > 0:
e4a41f
+            opts['supplier_ruv'] = ensure_list_str(supplier_ruv[0][1]['nsds50ruv'])
e4a41f
         else:
e4a41f
-            print("Error: Master does not have an RUV entry")
e4a41f
+            print("Error: Supplier does not have an RUV entry")
e4a41f
             sys.exit(1)
e4a41f
     except ldap.LDAPError as e:
e4a41f
-        print("Error: Failed to get Master RUV entry: {}".format(str(e)))
e4a41f
+        print("Error: Failed to get Supplier RUV entry: {}".format(str(e)))
e4a41f
         sys.exit(1)
e4a41f
 
e4a41f
     if opts['verbose']:
e4a41f
@@ -1067,12 +1067,12 @@ def connect_to_replicas(opts):
e4a41f
         print("Error: Failed to get Replica RUV entry: {}".format(str(e)))
e4a41f
         sys.exit(1)
e4a41f
 
e4a41f
-    # Get the master RID
e4a41f
+    # Get the Supplier RID
e4a41f
     if opts['verbose']:
e4a41f
-        print("Getting Master's replica ID")
e4a41f
+        print("Getting Supplier's replica ID")
e4a41f
     try:
e4a41f
         search_filter = "(&(objectclass=nsds5Replica)(nsDS5ReplicaRoot={})(nsDS5ReplicaId=*))".format(opts['suffix'])
e4a41f
-        replica_entry = master.search_s("cn=config", ldap.SCOPE_SUBTREE, search_filter)
e4a41f
+        replica_entry = supplier.search_s("cn=config", ldap.SCOPE_SUBTREE, search_filter)
e4a41f
         if len(replica_entry) > 0:
e4a41f
             opts['rid'] = ensure_int(replica_entry[0][1]['nsDS5ReplicaId'][0])
e4a41f
         else:
e4a41f
@@ -1081,7 +1081,7 @@ def connect_to_replicas(opts):
e4a41f
         print("Error: Failed to get Replica entry: {}".format(str(e)))
e4a41f
         sys.exit(1)
e4a41f
 
e4a41f
-    return (master, replica, opts)
e4a41f
+    return (supplier, replica, opts)
e4a41f
 
e4a41f
 
e4a41f
 def print_online_report(report, opts, output_file):
e4a41f
@@ -1104,11 +1104,11 @@ def print_online_report(report, opts, output_file):
e4a41f
     final_report += get_ruv_report(opts)
e4a41f
     final_report += ('Entry Counts\n')
e4a41f
     final_report += ('=====================================================\n\n')
e4a41f
-    final_report += ('Master:  %d\n' % (report['m_count']))
e4a41f
+    final_report += ('Supplier:  %d\n' % (report['m_count']))
e4a41f
     final_report += ('Replica: %d\n\n' % (report['r_count']))
e4a41f
     final_report += ('\nTombstones\n')
e4a41f
     final_report += ('=====================================================\n\n')
e4a41f
-    final_report += ('Master:  %d\n' % (report['mtombstones']))
e4a41f
+    final_report += ('Supplier:  %d\n' % (report['mtombstones']))
e4a41f
     final_report += ('Replica: %d\n' % (report['rtombstones']))
e4a41f
     final_report += report['conflict']
e4a41f
     missing = False
e4a41f
@@ -1121,7 +1121,7 @@ def print_online_report(report, opts, output_file):
e4a41f
             final_report += ('  Entries missing on Replica:\n')
e4a41f
             for entry in report['r_missing']:
e4a41f
                 if 'createtimestamp' in entry.data:
e4a41f
-                    final_report += ('   - %s  (Created on Master at: %s)\n' %
e4a41f
+                    final_report += ('   - %s  (Created on Supplier at: %s)\n' %
e4a41f
                                      (entry.dn, convert_timestamp(entry.data['createtimestamp'][0])))
e4a41f
                 else:
e4a41f
                     final_report += ('   - %s\n' % (entry.dn))
e4a41f
@@ -1129,7 +1129,7 @@ def print_online_report(report, opts, output_file):
e4a41f
         if m_missing > 0:
e4a41f
             if r_missing > 0:
e4a41f
                 final_report += ('\n')
e4a41f
-            final_report += ('  Entries missing on Master:\n')
e4a41f
+            final_report += ('  Entries missing on Supplier:\n')
e4a41f
             for entry in report['m_missing']:
e4a41f
                 if 'createtimestamp' in entry.data:
e4a41f
                     final_report += ('   - %s  (Created on Replica at: %s)\n' %
e4a41f
@@ -1146,9 +1146,9 @@ def print_online_report(report, opts, output_file):
e4a41f
     final_report += ('\nResult\n')
e4a41f
     final_report += ('=====================================================\n\n')
e4a41f
     if not missing and len(report['diff']) == 0:
e4a41f
-        final_report += ('No replication differences between Master and Replica\n')
e4a41f
+        final_report += ('No replication differences between Supplier and Replica\n')
e4a41f
     else:
e4a41f
-        final_report += ('There are replication differences between Master and Replica\n')
e4a41f
+        final_report += ('There are replication differences between Supplier and Replica\n')
e4a41f
 
e4a41f
     if output_file:
e4a41f
         output_file.write(final_report)
e4a41f
@@ -1170,7 +1170,7 @@ def remove_state_info(entry):
e4a41f
 
e4a41f
 def get_conflict_report(mentries, rentries, verbose):
e4a41f
     """Gather the conflict entry dn's for each replica
e4a41f
-    :param mentries - Master entries
e4a41f
+    :param mentries - Supplier entries
e4a41f
     :param rentries - Replica entries
e4a41f
     :param verbose - verbose logging
e4a41f
     :return - A text blob to dispaly in the report
e4a41f
@@ -1197,7 +1197,7 @@ def get_conflict_report(mentries, rentries, verbose):
e4a41f
         report = "\n\nConflict Entries\n"
e4a41f
         report += "=====================================================\n\n"
e4a41f
         if len(m_conflicts) > 0:
e4a41f
-            report += ('Master Conflict Entries:  %d\n' % (len(m_conflicts)))
e4a41f
+            report += ('Supplier Conflict Entries:  %d\n' % (len(m_conflicts)))
e4a41f
             if verbose:
e4a41f
                 for entry in m_conflicts:
e4a41f
                     report += ('\n - %s\n' % (entry['dn']))
e4a41f
@@ -1239,8 +1239,8 @@ def do_online_report(opts, output_file=None):
e4a41f
     rconflicts = []
e4a41f
     mconflicts = []
e4a41f
 
e4a41f
-    # Fire off paged searches on Master and Replica
e4a41f
-    master, replica, opts = connect_to_replicas(opts)
e4a41f
+    # Fire off paged searches on Supplier and Replica
e4a41f
+    supplier, replica, opts = connect_to_replicas(opts)
e4a41f
 
e4a41f
     if opts['verbose']:
e4a41f
         print('Start searching and comparing...')
e4a41f
@@ -1248,12 +1248,12 @@ def do_online_report(opts, output_file=None):
e4a41f
     controls = [paged_ctrl]
e4a41f
     req_pr_ctrl = controls[0]
e4a41f
     try:
e4a41f
-        master_msgid = master.search_ext(opts['suffix'], ldap.SCOPE_SUBTREE,
e4a41f
-                                         "(|(objectclass=*)(objectclass=ldapsubentry)(objectclass=nstombstone))",
e4a41f
-                                         ['*', 'createtimestamp', 'nscpentrywsi', 'nsds5replconflict'],
e4a41f
-                                         serverctrls=controls)
e4a41f
+        supplier_msgid = supplier.search_ext(opts['suffix'], ldap.SCOPE_SUBTREE,
e4a41f
+                                             "(|(objectclass=*)(objectclass=ldapsubentry)(objectclass=nstombstone))",
e4a41f
+                                             ['*', 'createtimestamp', 'nscpentrywsi', 'nsds5replconflict'],
e4a41f
+                                             serverctrls=controls)
e4a41f
     except ldap.LDAPError as e:
e4a41f
-        print("Error: Failed to get Master entries: %s", str(e))
e4a41f
+        print("Error: Failed to get Supplier entries: %s", str(e))
e4a41f
         sys.exit(1)
e4a41f
     try:
e4a41f
         replica_msgid = replica.search_ext(opts['suffix'], ldap.SCOPE_SUBTREE,
e4a41f
@@ -1268,11 +1268,11 @@ def do_online_report(opts, output_file=None):
e4a41f
     while not m_done or not r_done:
e4a41f
         try:
e4a41f
             if not m_done:
e4a41f
-                m_rtype, m_rdata, m_rmsgid, m_rctrls = master.result3(master_msgid)
e4a41f
+                m_rtype, m_rdata, m_rmsgid, m_rctrls = supplier.result3(supplier_msgid)
e4a41f
             elif not r_done:
e4a41f
                 m_rdata = []
e4a41f
         except ldap.LDAPError as e:
e4a41f
-            print("Error: Problem getting the results from the master: %s", str(e))
e4a41f
+            print("Error: Problem getting the results from the Supplier: %s", str(e))
e4a41f
             sys.exit(1)
e4a41f
         try:
e4a41f
             if not r_done:
e4a41f
@@ -1299,7 +1299,7 @@ def do_online_report(opts, output_file=None):
e4a41f
                                  report, opts)
e4a41f
 
e4a41f
         if not m_done:
e4a41f
-            # Master
e4a41f
+            # Supplier
e4a41f
             m_pctrls = [
e4a41f
                 c
e4a41f
                 for c in m_rctrls
e4a41f
@@ -1310,11 +1310,11 @@ def do_online_report(opts, output_file=None):
e4a41f
                     try:
e4a41f
                         # Copy cookie from response control to request control
e4a41f
                         req_pr_ctrl.cookie = m_pctrls[0].cookie
e4a41f
-                        master_msgid = master.search_ext(opts['suffix'], ldap.SCOPE_SUBTREE,
e4a41f
+                        supplier_msgid = supplier.search_ext(opts['suffix'], ldap.SCOPE_SUBTREE,
e4a41f
                             "(|(objectclass=*)(objectclass=ldapsubentry))",
e4a41f
                             ['*', 'createtimestamp', 'nscpentrywsi', 'conflictcsn', 'nsds5replconflict'], serverctrls=controls)
e4a41f
                     except ldap.LDAPError as e:
e4a41f
-                        print("Error: Problem searching the master: %s", str(e))
e4a41f
+                        print("Error: Problem searching the Supplier: %s", str(e))
e4a41f
                         sys.exit(1)
e4a41f
                 else:
e4a41f
                     m_done = True  # No more pages available
e4a41f
@@ -1354,7 +1354,7 @@ def do_online_report(opts, output_file=None):
e4a41f
     print_online_report(report, opts, output_file)
e4a41f
 
e4a41f
     # unbind
e4a41f
-    master.unbind_s()
e4a41f
+    supplier.unbind_s()
e4a41f
     replica.unbind_s()
e4a41f
 
e4a41f
 
e4a41f
@@ -1367,18 +1367,18 @@ def init_online_params(args):
e4a41f
 
e4a41f
     # Make sure the URLs are different
e4a41f
     if args.murl == args.rurl:
e4a41f
-        print("Master and Replica LDAP URLs are the same, they must be different")
e4a41f
+        print("Supplier and Replica LDAP URLs are the same, they must be different")
e4a41f
         sys.exit(1)
e4a41f
 
e4a41f
-    # Parse Master url
e4a41f
+    # Parse Supplier url
e4a41f
     if not ldapurl.isLDAPUrl(args.murl):
e4a41f
-        print("Master LDAP URL is invalid")
e4a41f
+        print("Supplier LDAP URL is invalid")
e4a41f
         sys.exit(1)
e4a41f
     murl = ldapurl.LDAPUrl(args.murl)
e4a41f
     if murl.urlscheme in VALID_PROTOCOLS:
e4a41f
         opts['mprotocol'] = murl.urlscheme
e4a41f
     else:
e4a41f
-        print('Unsupported ldap url protocol (%s) for Master, please use "ldaps" or "ldap"' %
e4a41f
+        print('Unsupported ldap url protocol (%s) for Supplier, please use "ldaps" or "ldap"' %
e4a41f
               murl.urlscheme)
e4a41f
         sys.exit(1)
e4a41f
 
e4a41f
@@ -1520,7 +1520,7 @@ def offline_report(args):
e4a41f
             print ("LDIF file ({}) is empty".format(ldif_dir))
e4a41f
             sys.exit(1)
e4a41f
     if opts['mldif'] == opts['rldif']:
e4a41f
-        print("The Master and Replica LDIF files must be different")
e4a41f
+        print("The Supplier and Replica LDIF files must be different")
e4a41f
         sys.exit(1)
e4a41f
 
e4a41f
     OUTPUT_FILE = None
e4a41f
@@ -1547,7 +1547,7 @@ def get_state(args):
e4a41f
     """Just do the RUV comparision
e4a41f
     """
e4a41f
     opts = init_online_params(args)
e4a41f
-    master, replica, opts = connect_to_replicas(opts)
e4a41f
+    supplier, replica, opts = connect_to_replicas(opts)
e4a41f
     print(get_ruv_state(opts))
e4a41f
 
e4a41f
 
e4a41f
@@ -1569,10 +1569,10 @@ def main():
e4a41f
     # Get state
e4a41f
     state_parser = subparsers.add_parser('state', help="Get the current replicaton state between two replicas")
e4a41f
     state_parser.set_defaults(func=get_state)
e4a41f
-    state_parser.add_argument('-m', '--master-url', help='The LDAP URL for the Master server',
e4a41f
-                               dest='murl', default=None, required=True)
e4a41f
+    state_parser.add_argument('-m', '--supplier-url', help='The LDAP URL for the Supplier server',
e4a41f
+                              dest='murl', default=None, required=True)
e4a41f
     state_parser.add_argument('-r', '--replica-url', help='The LDAP URL for the Replica server',
e4a41f
-                               dest='rurl', required=True, default=None)
e4a41f
+                              dest='rurl', required=True, default=None)
e4a41f
     state_parser.add_argument('-b', '--suffix', help='Replicated suffix', dest='suffix', required=True)
e4a41f
     state_parser.add_argument('-D', '--bind-dn', help='The Bind DN', required=True, dest='binddn', default=None)
e4a41f
     state_parser.add_argument('-w', '--bind-pw', help='The Bind password', dest='bindpw', default=None)
e4a41f
@@ -1586,7 +1586,7 @@ def main():
e4a41f
     # Online mode
e4a41f
     online_parser = subparsers.add_parser('online', help="Compare two online replicas for differences")
e4a41f
     online_parser.set_defaults(func=online_report)
e4a41f
-    online_parser.add_argument('-m', '--master-url', help='The LDAP URL for the Master server (REQUIRED)',
e4a41f
+    online_parser.add_argument('-m', '--supplier-url', help='The LDAP URL for the Supplier server (REQUIRED)',
e4a41f
                                dest='murl', default=None, required=True)
e4a41f
     online_parser.add_argument('-r', '--replica-url', help='The LDAP URL for the Replica server (REQUIRED)',
e4a41f
                                dest='rurl', required=True, default=None)
e4a41f
@@ -1612,12 +1612,12 @@ def main():
e4a41f
     # Offline LDIF mode
e4a41f
     offline_parser = subparsers.add_parser('offline', help="Compare two replication LDIF files for differences (LDIF file generated by 'db2ldif -r')")
e4a41f
     offline_parser.set_defaults(func=offline_report)
e4a41f
-    offline_parser.add_argument('-m', '--master-ldif', help='Master LDIF file',
e4a41f
+    offline_parser.add_argument('-m', '--supplier-ldif', help='Supplier LDIF file',
e4a41f
                                 dest='mldif', default=None, required=True)
e4a41f
     offline_parser.add_argument('-r', '--replica-ldif', help='Replica LDIF file',
e4a41f
                                 dest='rldif', default=None, required=True)
e4a41f
     offline_parser.add_argument('--rid', dest='rid', default=None, required=True,
e4a41f
-                                help='The Replica Identifer (rid) for the "Master" server')
e4a41f
+                                help='The Replica Identifier (rid) for the "Supplier" server')
e4a41f
     offline_parser.add_argument('-b', '--suffix', help='Replicated suffix', dest='suffix', required=True)
e4a41f
     offline_parser.add_argument('-c', '--conflicts', help='Display verbose conflict information', action='store_true',
e4a41f
                                 dest='conflicts', default=False)
e4a41f
-- 
e4a41f
2.31.1
e4a41f