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

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