Skip to content

Commit

Permalink
Merge pull request #64 from teicee/ceph-15
Browse files Browse the repository at this point in the history
Ceph 15.2.5
  • Loading branch information
Crapworks authored Apr 27, 2021
2 parents 57b9c81 + b9054aa commit e36f4eb
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions app/dashboard/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,14 @@ def get(self):
if 'err' in cluster_status:
abort(500, cluster_status['err'])

# ceph >= 15.2.5
if 'osdmap' not in cluster_status['osdmap']:
# osdmap has been converted to depth-1 dict
cluster_status['osdmap']['osdmap'] = cluster_status['osdmap'].copy()
monitor_status = CephClusterCommand(cluster, prefix='quorum_status', format='json')
cluster_status['monmap'] = monitor_status['monmap']


# check for unhealthy osds and get additional osd infos from cluster
total_osds = cluster_status['osdmap']['osdmap']['num_osds']
in_osds = cluster_status['osdmap']['osdmap']['num_up_osds']
Expand Down

0 comments on commit e36f4eb

Please sign in to comment.