We need the ability to flexibly and efficiently emit derived meters, where the sample values are calculated from a primary meter in the form of a rate-of-change or unit scaling conversion. This should be achievable via a generic transformer, where the scaling rule is defined in configuration, as opposed to requiring that new pollsters are written on a case-by-case basis. The canonical example would be the cpu_util meter, which requires that CPU utilization % is calculated on the basis of the first derivative of the cumulative CPU time for an instance. The existing pollster that currently emits this derived meter should be obsoleted in favour of the generic transformer, appropriately configured: - name: meter_pipeline interval: 600 counters: - "*" transformers: publishers: - rpc:// - name: cpu_pipeline interval: 60 counters: - "cpu" transformers: - name: "rate_of_change" parameters: target: name: "cpu_util" unit: "%" type: "gauge" scale: "100.0 / (10**9 * (resource_metadata.cpu_number or 1))" replace: False publishers: - rpc:// Upstream blueprint: https://blueprints.launchpad.net/ceilometer/+spec/transformer-unit
How To Test =========== 0. Install packstack allinone, then spin up an instance in the usual way. 1. Ensure the old cpu_util pollster is no longer loaded: sudo grep cpu_util /usr/lib/python2.?/site-packages/ceilometer-2013*.egg-info/entry_points.txt # (no output expected) whereas the primary cpu pollster is still loaded: sudo grep '\<cpu\> /usr/lib/python2.?/site-packages/ceilometer-2013*.egg-info/entry_points.txt 2. Ensure that the cpu and cpu_util meters can be configured with independent cadences: sudo sed -i '/^ *name: cpu_pipeline$/ { n ; s/interval: 600$/interval: 60/ }' /etc/ceilometer/pipeline.yaml sudo service openstack-ceilometer-compute restart sleep 300 ceilometer sample-list -m cpu ceilometer sample-list -m cpu_util Confirm that the over the most recent time period, the cpu_util is being reported approximately at a ratio of 10:1 in frequency as compared to the cpu meter.
QANAK'ing due to QE capacity
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHEA-2013-1859.html