mirror of
https://git.proxmox.com/git/pve-manager
synced 2025-08-16 11:04:41 +00:00
ceph: a little luminous backwards compatibility
ceph luminous does not use the 'name' property in the metadata everywhere, so fall back to 'id' this makes the ceph dashboard usable while having still luminous (relevant for upgrading) Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
06064872c2
commit
46fb9c5017
@ -664,7 +664,7 @@ __PACKAGE__->register_method ({
|
||||
my $services = $rados->mon_command({ prefix => "$type metadata" });
|
||||
for my $service ( @$services ) {
|
||||
my $hostname = $service->{hostname};
|
||||
my $servicename = $service->{name};
|
||||
my $servicename = $service->{name} // $service->{id};
|
||||
my $id = "$servicename\@$hostname";
|
||||
|
||||
if ($data->{$id}) {
|
||||
|
@ -111,7 +111,8 @@ sub get_services_info {
|
||||
}
|
||||
my $metadata = $rados->mon_command({ prefix => "$type metadata" });
|
||||
foreach my $info (@$metadata) {
|
||||
my $service = $result->{$info->{name}};
|
||||
my $id = $info->{name} // $info->{id};
|
||||
my $service = $result->{$id};
|
||||
$service->{ceph_version_short} = $info->{ceph_version_short};
|
||||
$service->{ceph_version} = $info->{ceph_version};
|
||||
$service->{host} //= $info->{hostname};
|
||||
|
Loading…
Reference in New Issue
Block a user