www/DataStoreStatus.js: display swap stats

This commit is contained in:
Dietmar Maurer 2020-05-25 10:39:54 +02:00
parent 3f23b17298
commit c1b24fbf0b
2 changed files with 12 additions and 1 deletions

View File

@ -29,7 +29,7 @@ fn get_node_stats(
crate::rrd::extract_data( crate::rrd::extract_data(
"host", "host",
&["cpu", "iowait", "memtotal", "memused", "netin", "netout"], &["cpu", "iowait", "memtotal", "memused", "swaptotal", "swapused", "netin", "netout"],
timeframe, timeframe,
cf, cf,
) )

View File

@ -29,6 +29,8 @@ Ext.define('pve-rrd-node', {
'netout', 'netout',
'memtotal', 'memtotal',
'memused', 'memused',
'swaptotal',
'swapused',
{ type: 'date', dateFormat: 'timestamp', name: 'time' } { type: 'date', dateFormat: 'timestamp', name: 'time' }
] ]
}); });
@ -41,6 +43,8 @@ Ext.define('PBS.DataStoreStatus', {
title: gettext('Data Store Status'), title: gettext('Data Store Status'),
tbar: ['->', { xtype: 'proxmoxRRDTypeSelector' } ], tbar: ['->', { xtype: 'proxmoxRRDTypeSelector' } ],
scrollable: true,
initComponent: function() { initComponent: function() {
var me = this; var me = this;
@ -76,6 +80,13 @@ Ext.define('PBS.DataStoreStatus', {
fieldTitles: [gettext('Total'), gettext('RAM usage')], fieldTitles: [gettext('Total'), gettext('RAM usage')],
store: rrdstore store: rrdstore
}, },
{
xtype: 'proxmoxRRDChart',
title: gettext('Swap usage'),
fields: ['swaptotal','swapused'],
fieldTitles: [gettext('Total'), gettext('Swap usage')],
store: rrdstore
},
{ {
xtype: 'proxmoxRRDChart', xtype: 'proxmoxRRDChart',
title: gettext('Network traffic'), title: gettext('Network traffic'),