OpenStack Victoria : How to use Ceilometer (Cinder)2020/11/20 |
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 | | L2 Agent | | Nova Compute | | Keystone Glance | | L3 Agent | | Open vSwitch | | Nova API Cinder API | | Metadata Agent | | L2 Agent | | Neutron Server | | Cinder Volume | | Ceilometer Compute | | Metadata Agent | | Heat API | | | | Gnocchi | | Heat Engine | | | | 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 openstack-cinder-api openstack-cinder-scheduler |
[2] | It's some example to display metrics and meters. |
# list resources [cent@dlp ~(keystone)]$ openstack metric resource list +--------------------------------------+----------------------------+---------------------------------- | id | type | project_id +--------------------------------------+----------------------------+---------------------------------- | 852fbb21-1dd6-4268-9532-54876bbc4567 | instance | 8cc9f93ed89f40e28a610d025462c... | 66daeeec-3425-5ef9-97e6-4799ce18dea5 | instance_disk | 8cc9f93ed89f40e28a610d025462c... | a13ba637-1038-5ce5-9f0e-8aac70952d47 | instance_network_interface | 8cc9f93ed89f40e28a610d025462c... +--------------------------------------+----------------------------+---------------------------------- # test to create a volume [cent@dlp ~(keystone)]$ openstack volume create --size 10 disk01 # list resources [cent@dlp ~(keystone)]$ openstack metric resource list +--------------------------------------+----------------------------+---------------------------------- | id | type | project_id +--------------------------------------+----------------------------+---------------------------------- | 852fbb21-1dd6-4268-9532-54876bbc4567 | instance | 8cc9f93ed89f40e28a610d025462c... | 66daeeec-3425-5ef9-97e6-4799ce18dea5 | instance_disk | 8cc9f93ed89f40e28a610d025462c... | a13ba637-1038-5ce5-9f0e-8aac70952d47 | instance_network_interface | 8cc9f93ed89f40e28a610d025462c... | c8851075-c92f-4aab-bc69-fd571d79562b | volume | 8cc9f93ed89f40e28a610d025462c... +--------------------------------------+----------------------------+---------------------------------- # details of the resource [cent@dlp ~(keystone)]$ openstack metric resource show c8851075-c92f-4aab-bc69-fd571d79562b +-----------------------+-------------------------------------------------------------------+ | Field | Value | +-----------------------+-------------------------------------------------------------------+ | created_by_project_id | 4e42859fe8704e8aaddb5369551b6c52 | | created_by_user_id | fa8f7a76bb114819950cfd6b99238fee | | creator | fa8f7a76bb114819950cfd6b99238fee:4e42859fe8704e8aaddb5369551b6c52 | | ended_at | None | | id | c8851075-c92f-4aab-bc69-fd571d79562b | | metrics | volume.size: 3d1d27a4-371f-4bec-8b63-6587b19e9445 | | original_resource_id | c8851075-c92f-4aab-bc69-fd571d79562b | | project_id | 8cc9f93ed89f40e28a610d025462c020 | | revision_end | None | | revision_start | 2020-11-20T08:11:55.395302+00:00 | | started_at | 2020-11-20T08:11:55.395295+00:00 | | type | volume | | user_id | bb4ae84eefc04357987ec43b8e93118c | +-----------------------+-------------------------------------------------------------------+ # display volume size data [cent@dlp ~(keystone)]$ openstack metric measures show 3d1d27a4-371f-4bec-8b63-6587b19e9445 +---------------------------+-------------+-------+ | timestamp | granularity | value | +---------------------------+-------------+-------+ | 2020-11-20T17:10:00+09:00 | 300.0 | 10.0 | +---------------------------+-------------+-------+ |
Sponsored Link |
|