]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/telemetry: note whether osd cluster_network is in use
authorSage Weil <sage@redhat.com>
Tue, 29 Oct 2019 18:20:07 +0000 (13:20 -0500)
committerSage Weil <sage@redhat.com>
Wed, 6 Nov 2019 12:41:50 +0000 (06:41 -0600)
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 702175f49361f3875c5e356c812d45e34d01a021)

PendingReleaseNotes
src/pybind/mgr/telemetry/module.py

index ee6cf2625e6a035a6b95ecf73b2a442bc1ea7aca..903add1c8f1f55397543eabc077db6b21b2d350b 100644 (file)
@@ -64,6 +64,7 @@
     - whether pools are replicated or erasure coded, and
       which erasure code profile plugin and parameters are in use
     - how many hosts are in the cluster, and how many hosts have each type of daemon
+    - whether a separate OSD cluster network is being used
 
   If you had telemetry enabled, you will need to re-opt-in with::
 
index 114629d39952006807d8243b6e2ede9d39642eea..5de53a30845429855f89e6cc30f503c85bd7db0e 100644 (file)
@@ -52,6 +52,7 @@ REVISION = 3
 #   - remove crush_rule
 #   - added more pool metadata (rep vs ec, cache tiering mode, ec profile)
 #   - added host count, and counts for hosts with each of (mon, osd, mds, mgr)
+#   - whether an OSD cluster network is in use
 
 class Module(MgrModule):
     config = dict()
@@ -446,10 +447,18 @@ class Module(MgrModule):
                 )
 
             # osds
+            cluster_network = False
+            for osd in osd_map['osds']:
+                if osd['up'] and not cluster_network:
+                    front_ip = osd['public_addrs']['addrvec'][0]['addr'].split(':')[0]
+                    back_ip = osd['public_addrs']['addrvec'][0]['addr'].split(':')[0]
+                    if front_ip != back_ip:
+                        cluster_network = True
             report['osd'] = {
                 'count': len(osd_map['osds']),
                 'require_osd_release': osd_map['require_osd_release'],
-                'require_min_compat_client': osd_map['require_min_compat_client']
+                'require_min_compat_client': osd_map['require_min_compat_client'],
+                'cluster_network': cluster_network,
             }
 
             # cephfs