ISSUE TYPE
COMPONENT NAME
CLOUDSTACK VERSION
CONFIGURATION
OS / ENVIRONMENT
Irrelevant.
SUMMARY
The prometheus integration returns inconsistent capacity values when a host is in "maintenance" and cloudstack-management service is restarted.
STEPS TO REPRODUCE
1. Set "maintenance" status for a host
2. In database, the capacity rows are deleted in the op_host_capacity table, for the said host
3. Prometheus integration returns capacities with value=0
4. Restart cloudstack-management service while the host is still in maintenance
5. In database, table op_host_capacity is populated, with capacity_state = Disabled
6. Prometheus integration now returns capacity values from used/total_capacity columns, ignoring the capacity_state
EXPECTED RESULTS
Prometheus integration returns capacity values=0 when the capacity is missing (eg. host is in maintenance) or when the capacity_state is set at Disabled (eg. host in maintenance and service is restarted)
ACTUAL RESULTS
Prometheus integration returns capacity values all the time as long as the used/total_capacity columns exist, ignoring when the capacity_state is Disabled.
ISSUE TYPE
COMPONENT NAME
CLOUDSTACK VERSION
CONFIGURATION
OS / ENVIRONMENT
Irrelevant.
SUMMARY
The prometheus integration returns inconsistent capacity values when a host is in "maintenance" and cloudstack-management service is restarted.
STEPS TO REPRODUCE
EXPECTED RESULTS
ACTUAL RESULTS