Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1505753

Summary: [GSS]We can't get disk usage for instance if the storage back is Ceph rbd.
Product: Red Hat OpenStack Reporter: liuwei <wliu>
Component: openstack-ceilometerAssignee: Julien Danjou <jdanjou>
Status: CLOSED ERRATA QA Contact: Sasha Smolyak <ssmolyak>
Severity: medium Docs Contact:
Priority: medium    
Version: 10.0 (Newton)CC: cchen, dvd, jdanjou, jruzicka, lruzicka, mabaakou, marjones, srevivo, ssmolyak, wliu
Target Milestone: z7Keywords: Reopened, Triaged, ZStream
Target Release: 10.0 (Newton)   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: openstack-ceilometer-7.1.1-4 Doc Type: Bug Fix
Doc Text:
Originally, when a Nova instance was running with a disk backed by Ceph, Ceilometer ignored the disk meters. The problem has been fixed. As a result, Ceilometer properly polls these meters.
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-04-18 17:00:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description liuwei 2017-10-24 08:41:04 UTC
Description of problem:

We can't get disk usage for instance  if the storage back is Ceph rbd.  The warning messages in the ceilometer/compute.log as the below shown:

2017-10-22 08:48:59.173 4240 WARNING ceilometer.compute.virt.libvirt.inspector [-] Inspection disk usage of network disk e128ae1c-8ac5-47a9-a407-e07eb4b2c767 unsupported by libvirt
2017-10-22 08:48:59.178 4240 WARNING ceilometer.compute.virt.libvirt.inspector [-] Inspection disk usage of network disk 88bef72c-905f-4814-9d72-911e29c9ae87 unsupported by libvirt
2017-10-22 08:48:59.182 4240 WARNING ceilometer.compute.virt.libvirt.inspector [-] Inspection disk usage of network disk 32887f30-23be-4867-85ec-c4396579dfc9 unsupported by libvirt
2017-10-22 08:48:59.186 4240 WARNING ceilometer.compute.virt.libvirt.inspector [-] Inspection disk usage of network disk 629c0d62-6eef-4563-b9b5-0a5baeb5f07b unsupported by libvirt 

Then for the gnochhi command output , all disk usage is Zero. 


gnocchi measures show 05fa5cfc-349e-4ab9-a7b2-9a3d66124d19

+---------------------------+-------------+-------+
| timestamp                 | granularity | value |
+---------------------------+-------------+-------+
| 2017-09-18T00:00:00+00:00 |     86400.0 |   0.0 |
| 2017-09-19T00:00:00+00:00 |     86400.0 |   0.0 |
| 2017-09-18T12:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T13:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T14:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T15:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T16:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T17:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T18:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T19:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T20:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T21:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T22:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-18T23:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T00:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T01:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T02:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T03:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T04:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T05:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T06:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T07:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T08:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T09:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T10:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T11:00:00+00:00 |      3600.0 |   0.0 |
| 2017-09-19T09:25:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T09:35:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T09:45:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T09:55:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T10:05:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T10:15:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T10:25:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T10:35:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T10:45:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T10:55:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T11:05:00+00:00 |       300.0 |   0.0 |
| 2017-09-19T11:15:00+00:00 |       300.0 |   0.0 |

It looks like the gnocchi bug I think.  From the upstrea site, I found the below patch :

https://review.openstack.org/#/c/513681

So, Could we backport this patch to our related packages ?



Version-Release number of selected component (if applicable):

 cat overcloud-compute-0.localdomain/installed-rpms | grep ceilometer

openstack-ceilometer-api-7.1.0-4.el7ost.noarch              Wed Oct 18 04:31:54 2017
openstack-ceilometer-central-7.1.0-4.el7ost.noarch          Wed Oct 18 04:31:54 2017
openstack-ceilometer-collector-7.1.0-4.el7ost.noarch        Wed Oct 18 04:31:54 2017
openstack-ceilometer-common-7.1.0-4.el7ost.noarch           Wed Oct 18 04:31:53 2017
openstack-ceilometer-compute-7.1.0-4.el7ost.noarch          Wed Oct 18 04:31:54 2017
openstack-ceilometer-ipmi-7.1.0-4.el7ost.noarch             Wed Oct 18 04:32:21 2017
openstack-ceilometer-notification-7.1.0-4.el7ost.noarch     Wed Oct 18 04:31:54 2017
openstack-ceilometer-polling-7.1.0-4.el7ost.noarch          Wed Oct 18 04:31:53 2017
puppet-ceilometer-9.4.0-2.el7ost.noarch                     Mon Dec 12 18:38:00 2016
python-ceilometer-7.1.0-4.el7ost.noarch                     Wed Oct 18 04:31:53 2017
python-ceilometer-tests-7.1.0-4.el7ost.noarch               Wed Oct 18 04:32:20 2017
python-ceilometerclient-2.6.2-1.el7ost.noarch               Mon Dec 12 18:07:26 2016
python-ceilometermiddleware-0.5.1-1.el7ost.noarch           Mon Dec 12 18:14:20 2016

cat overcloud-compute-0.localdomain/installed-rpms | grep gnocchi
openstack-gnocchi-api-3.0.2-1.el7ost.noarch                 Mon Dec 12 18:32:47 2016
openstack-gnocchi-carbonara-3.0.2-1.el7ost.noarch           Mon Dec 12 18:32:43 2016
openstack-gnocchi-common-3.0.2-1.el7ost.noarch              Mon Dec 12 18:32:42 2016
openstack-gnocchi-indexer-sqlalchemy-3.0.2-1.el7ost.noarch  Mon Dec 12 18:32:42 2016
openstack-gnocchi-metricd-3.0.2-1.el7ost.noarch             Mon Dec 12 18:32:49 2016
openstack-gnocchi-statsd-3.0.2-1.el7ost.noarch              Mon Dec 12 18:32:48 2016
puppet-gnocchi-9.4.1-1.el7ost.noarch                        Mon Dec 12 18:38:01 2016
python-gnocchi-3.0.2-1.el7ost.noarch                        Mon Dec 12 18:32:41 2016
python-gnocchiclient-2.6.0-1.el7ost.noarch                  Mon Dec 12 18:25:12 2016


How reproducible:

100% reporduced


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 11 errata-xmlrpc 2017-11-15 13:43:00 UTC
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.

https://access.redhat.com/errata/RHBA-2017:3228

Comment 29 Julien Danjou 2017-11-24 12:53:11 UTC
The backported patch should work in this case AFAICS. Did you check ceilometer-compute log file on the host running this VM?

Also this VM has 3 disks attached to it. Are you sure you are checking the metrics of the *DISK* and the metrics of the *INSTANCE*?

Comment 30 Chen 2017-11-30 14:01:29 UTC
Hi jd,

I checked the newest ceilometer/compute.log and I didn't find any logs related to disk.usage polling.

$ grep 'disk.usage' compute.log | wc -l
0

Then I looked at the compute.log to find out the config file when the ceilometer-compute starts. I didn't find disk.usage in the config as well.

2017-11-30 09:13:27.724 972547 INFO ceilometer.pipeline [-] Config file: {'sources': [{'interval': 600, 'meters': ['cpu', 'memory.usage', 'network.incoming.bytes', 'network.incoming.packets', 'network.outgoing.bytes', 'network.outgoing.packets', 'disk.read.bytes', 'disk.read.requests', 'disk.write.bytes', 'disk.write.requests', 'hardware.cpu.util', 'hardware.memory.used', 'hardware.memory.total', 'hardware.memory.buffer', 'hardware.memory.cached', 'hardware.memory.swap.avail', 'hardware.memory.swap.total', 'hardware.system_stats.io.outgoing.blocks', 'hardware.system_stats.io.incoming.blocks', 'hardware.network.ip.incoming.datagrams', 'hardware.network.ip.outgoing.datagrams'], 'name': 'some_pollsters', 'sinks': ['meter_sink']}, {'interval': 600, 'meters': ['cpu'], 'name': 'cpu_source', 'sinks': ['cpu_sink', 'cpu_delta_sink']}, {'interval': 600, 'meters': ['disk.read.bytes', 'disk.read.requests', 'disk.write.bytes', 'disk.write.requests', 'disk.device.read.bytes', 'disk.device.read.requests', 'disk.device.write.bytes', 'disk.device.write.requests'], 'name': 'disk_source', 'sinks': ['disk_sink']}, {'interval': 600, 'meters': ['network.incoming.bytes', 'network.incoming.packets', 'network.outgoing.bytes', 'network.outgoing.packets'], 'name': 'network_source', 'sinks': ['network_sink']}], 'sinks': [{'publishers': ['notifier://'], 'transformers': None, 'name': 'meter_sink'}, {'publishers': ['notifier://'], 'transformers': [{'name': 'rate_of_change', 'parameters': {'target': {'max': 100, 'scale': '100.0 / (10**9 * (resource_metadata.cpu_number or 1))', 'type': 'gauge', 'name': 'cpu_util', 'unit': '%'}}}], 'name': 'cpu_sink'}, {'publishers': ['notifier://'], 'transformers': [{'name': 'delta', 'parameters': {'target': {'name': 'cpu.delta'}, 'growth_only': True}}], 'name': 'cpu_delta_sink'}, {'publishers': ['notifier://'], 'transformers': [{'name': 'rate_of_change', 'parameters': {'source': {'map_from': {'name': '(disk\\.device|disk)\\.(read|write)\\.(bytes|requests)', 'unit': '(B|request)'}}, 'target': {'map_to': {'name': '\\1.\\2.\\3.rate', 'unit': '\\1/s'}, 'type': 'gauge'}}}], 'name': 'disk_sink'}, {'publishers': ['notifier://'], 'transformers': [{'name': 'rate_of_change', 'parameters': {'source': {'map_from': {'name': 'network\\.(incoming|outgoing)\\.(bytes|packets)', 'unit': '(B|packet)'}}, 'target': {'map_to': {'name': 'network.\\1.\\2.rate', 'unit': '\\1/s'}, 'type': 'gauge'}}}], 'name': 'network_sink'}]}

My understanding is that the python-ceilometer-compute will read /etc/ceilometer/polling.yaml to decide which metrics are going to be collected in OSP10. But from the above it seems that ceilometer-compute was using /etc/ceilometer/pipeline.yaml. So I am confused about the real configuration which will be used by ceilometer-compute. Would you please help me to identify this ?

Best Regards,
Chen