mirror of
https://git.proxmox.com/git/pve-manager
synced 2025-08-14 05:07:31 +00:00
ceph: extend the pool view
to add the pg_autoscale_mode since its activated in Ceph Octopus by default and emmits a waring (ceph status) if a pool has too many PGs. Signed-off-by: Alwin Antreich <a.antreich@proxmox.com>
This commit is contained in:
parent
fdf79b4e66
commit
06bd1c5215
@ -607,6 +607,7 @@ __PACKAGE__->register_method ({
|
|||||||
pool => { type => 'integer' },
|
pool => { type => 'integer' },
|
||||||
pool_name => { type => 'string' },
|
pool_name => { type => 'string' },
|
||||||
size => { type => 'integer' },
|
size => { type => 'integer' },
|
||||||
|
pg_autoscale_mode => { type => 'string', optional => 1 },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
links => [ { rel => 'child', href => "{pool_name}" } ],
|
links => [ { rel => 'child', href => "{pool_name}" } ],
|
||||||
@ -636,9 +637,19 @@ __PACKAGE__->register_method ({
|
|||||||
}
|
}
|
||||||
|
|
||||||
my $data = [];
|
my $data = [];
|
||||||
|
my $attr_list = [
|
||||||
|
'pool',
|
||||||
|
'pool_name',
|
||||||
|
'size',
|
||||||
|
'min_size',
|
||||||
|
'pg_num',
|
||||||
|
'crush_rule',
|
||||||
|
'pg_autoscale_mode',
|
||||||
|
];
|
||||||
|
|
||||||
foreach my $e (@{$res->{pools}}) {
|
foreach my $e (@{$res->{pools}}) {
|
||||||
my $d = {};
|
my $d = {};
|
||||||
foreach my $attr (qw(pool pool_name size min_size pg_num crush_rule)) {
|
foreach my $attr (@$attr_list) {
|
||||||
$d->{$attr} = $e->{$attr} if defined($e->{$attr});
|
$d->{$attr} = $e->{$attr} if defined($e->{$attr});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -107,10 +107,21 @@ Ext.define('PVE.node.CephPoolList', {
|
|||||||
dataIndex: 'size'
|
dataIndex: 'size'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: '# Placement Groups', // pg_num',
|
text: 'Placement Groups',
|
||||||
width: 180,
|
columns: [
|
||||||
align: 'right',
|
{
|
||||||
dataIndex: 'pg_num'
|
text: '# of PGs', // pg_num',
|
||||||
|
width: 100,
|
||||||
|
align: 'right',
|
||||||
|
dataIndex: 'pg_num'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
text: 'Autoscale Mode',
|
||||||
|
width: 140,
|
||||||
|
align: 'right',
|
||||||
|
dataIndex: 'pg_autoscale_mode'
|
||||||
|
},
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: 'CRUSH Rule',
|
text: 'CRUSH Rule',
|
||||||
|
Loading…
Reference in New Issue
Block a user