OpenStack Yoga : How to use Ceilometer (Cinder)2022/04/12 |
This is how to use OpenStack Telemetry Service (Ceilometer) for Cinder service.
This example is based on the environment like follows.
------------+---------------------------+---------------------------+------------ | | | eth0|10.0.0.30 eth0|10.0.0.50 eth0|10.0.0.51 +-----------+-----------+ +-----------+-----------+ +-----------+-----------+ | [ Control Node ] | | [ Storage Node ] | | [ Compute Node ] | | | | | | | | MariaDB RabbitMQ | | Open vSwitch | | Libvirt | | Memcached httpd | | Neutron Server | | Nova Compute | | Keystone Glance | | OVN-Northd | | Open vSwitch | | Nova API | | Cinder Volume | | OVN Metadata Agent | | Cinder API | | Heat API/Engine | | OVN-Controller | | | | Gnocchi httpd | | Ceilometer Compute | | | | Ceilometer Central | | | +-----------------------+ +-----------------------+ +-----------------------+ |
[1] | Change settings for Cinder service to enable Telemetry data collention like follows. Change on all Nodes Cinder services are running. |
root@dlp ~(keystone)#
vi /etc/cinder/cinder.conf # add to the end [oslo_messaging_notifications] driver = messagingv2 transport_url = rabbit://openstack:password@10.0.0.30 systemctl restart apache2 cinder-scheduler |
[2] | It's some examples to display metrics and meters. |
# display resources ubuntu@dlp ~(keystone)$ openstack metric resource list +--------------------------------------+----------------------------+---------------------------------- | id | type | project_id +--------------------------------------+----------------------------+---------------------------------- | 7ea894ee-3a91-4541-96ba-717ff45917c5 | instance | d3434f55aa5541cfab5f13916da06... | 250af39c-0514-5aab-b416-7f01b8b01e19 | instance_disk | d3434f55aa5541cfab5f13916da06... | cb389274-fbb8-536a-9df0-a8d5d6bc8a2f | instance_network_interface | d3434f55aa5541cfab5f13916da06... +--------------------------------------+----------------------------+---------------------------------- # test to create a volume ubuntu@dlp ~(keystone)$ openstack volume create --size 10 disk01 # display resources ubuntu@dlp ~(keystone)$ openstack metric resource list +--------------------------------------+----------------------------+---------------------------------- | id | type | project_id +--------------------------------------+----------------------------+---------------------------------- | 7ea894ee-3a91-4541-96ba-717ff45917c5 | instance | d3434f55aa5541cfab5f13916da0697d | 250af39c-0514-5aab-b416-7f01b8b01e19 | instance_disk | d3434f55aa5541cfab5f13916da0697d | cb389274-fbb8-536a-9df0-a8d5d6bc8a2f | instance_network_interface | d3434f55aa5541cfab5f13916da0697d | 0875aa46-3e39-4e37-9720-e850f5e7beec | volume | d3434f55aa5541cfab5f13916da0697d +--------------------------------------+----------------------------+---------------------------------- # details of [volume] resource ubuntu@dlp ~(keystone)$ openstack metric resource show 0875aa46-3e39-4e37-9720-e850f5e7beec +-----------------------+-------------------------------------------------------------------+ | Field | Value | +-----------------------+-------------------------------------------------------------------+ | created_by_project_id | c043fb355eff47e69642adfcd7a55620 | | created_by_user_id | 4dde18e4717d4936ad5dea946de3d41f | | creator | 4dde18e4717d4936ad5dea946de3d41f:c043fb355eff47e69642adfcd7a55620 | | ended_at | None | | id | 0875aa46-3e39-4e37-9720-e850f5e7beec | | metrics | volume.size: 1fe73c47-2f3e-48b3-be9f-8c807f4cce7d | | original_resource_id | 0875aa46-3e39-4e37-9720-e850f5e7beec | | project_id | d3434f55aa5541cfab5f13916da0697d | | revision_end | None | | revision_start | 2022-04-12T00:42:59.909416+00:00 | | started_at | 2022-04-12T00:42:59.909409+00:00 | | type | volume | | user_id | 95f196a1851c4b93b016871f7d5ded82 | +-----------------------+-------------------------------------------------------------------+ # display volume size data ubuntu@dlp ~(keystone)$ openstack metric measures show 1fe73c47-2f3e-48b3-be9f-8c807f4cce7d +---------------------------+-------------+-------+ | timestamp | granularity | value | +---------------------------+-------------+-------+ | 2022-04-12T09:40:00+09:00 | 300.0 | 10.0 | +---------------------------+-------------+-------+ |
Sponsored Link |
|