mgr/dashboard: Read/Write OPS in pool stats always show 0
In the dashboard 'Pools' widget the Read/Write ops are always 0. I assume the CephService::get_pool_list_with_stats method is doing something wrong.
#2 Updated by John Spray 8 months ago
- Assignee deleted (
The get_pool_list_with_stats implementation looks strange to me.
It seems to be trying to construct some deque time series in pool_stats, but pool_stats is a local that's construct each time the function is called. The later call to get_rate is probably always returning 0 because the length of the series is only ever 1.
Look at how update_pool_stats is used in the luminous dashboard -- it's called each time we get a pg_summary notification, and maintains the time series as an attribute of the MgrModule instance, so that it's always there when something else wants to read it.
#4 Updated by Lenz Grimmer 7 months ago
Just to elaborate on this a bit (thank you John for the clarification on IRC): this needs to be fixed in the Ceph Manager dashboard module backend:
The underlying ceph-mgr bits just give the current statistics (via the pgmap summary) -- the calculation of the rate would happen in the dashboard