OpenStack Yoga : Ceilometer 利用方法 (Glance)2022/06/13 |
OpenStack Telemetry Service (Ceilometer) の利用方法です。
当例では以下のような環境を例に Ceilometer サービスをインストールしています。
------------+-----------------------------+-----------------------------+------------ | | | eth0|10.0.0.30 eth0|10.0.0.50 eth0|10.0.0.51 +-----------+-----------+ +-----------+-----------+ +-----------+-----------+ | [ dlp.srv.world ] | | [ network.srv.world ] | | [ node01.srv.world ] | | (Control Node) | | (Network Node) | | (Compute Node) | | | | | | | | MariaDB RabbitMQ | | Open vSwitch | | Libvirt | | Memcached httpd | | Neutron Server | | Nova Compute | | Keystone Glance | | OVN-Northd | | Open vSwitch | | Nova API Cinder API | | Cinder Volume | | OVN Metadata Agent | | | | Gnocchi httpd | | OVN-Controller | | | | Ceilometer Central | | Ceilometer Compute | +-----------------------+ +-----------------------+ +-----------------------+ |
[1] | Image サービスの各種データ収集を有効にするには、Glance を以下のように設定します。 |
[root@dlp ~(keystone)]#
vi /etc/glance/glance-api.conf # 最終行へ追記 [oslo_messaging_notifications] driver = messagingv2 # RabbitMQ 接続情報 transport_url = rabbit://openstack:password@dlp.srv.world systemctl restart openstack-glance-api |
[2] | イメージを追加等した場合に収集されるデータの表示例です。 |
# リソース一覧 [root@dlp ~(keystone)]# openstack metric resource list +--------------------------------------+----------------------------+---------------------------------- | id | type | project_id +--------------------------------------+----------------------------+---------------------------------- | 25ef320e-b16e-4085-96ef-af7fa0d33cfb | instance | 911e5ff7686741c782d6acc6d7155... | f7e5361a-fd6c-568a-a718-0168c5ae2c65 | instance_network_interface | 911e5ff7686741c782d6acc6d7155... | 4f70f768-ed81-58c8-be82-704e89dfc79d | instance_disk | 911e5ff7686741c782d6acc6d7155... +--------------------------------------+----------------------------+----------------------------------[root@dlp ~(keystone)]# openstack image list +--------------------------------------+----------------+--------+ | ID | Name | Status | +--------------------------------------+----------------+--------+ | 1044ab46-c42b-4cf6-ab1f-aaeb011fb3b9 | CentOS-Stream9 | active | +--------------------------------------+----------------+--------+ # テストとしてイメージダウンロード [root@dlp ~(keystone)]# openstack image save --file centos-st9.qcow2 CentOS-Stream9 # テストとしてイメージ登録 [root@dlp ~(keystone)]# openstack image create "CentOS-ST9" --file centos-st9.qcow2 --disk-format qcow2 --container-format bare --public # リソース一覧 [root@dlp ~(keystone)]# openstack metric resource list +--------------------------------------+----------------------------+---------------------------------- | id | type | project_id +--------------------------------------+----------------------------+---------------------------------- | 25ef320e-b16e-4085-96ef-af7fa0d33cfb | instance | 911e5ff7686741c782d6acc6d7155... | f7e5361a-fd6c-568a-a718-0168c5ae2c65 | instance_network_interface | 911e5ff7686741c782d6acc6d7155... | 4f70f768-ed81-58c8-be82-704e89dfc79d | instance_disk | 911e5ff7686741c782d6acc6d7155... | dfa1b649-0333-4a70-98f6-77699df1d235 | image | 9c8b7457e8db4cbc995a767706804... +--------------------------------------+----------------------------+---------------------------------- # [image] リソース詳細 [root@dlp ~(keystone)]# openstack metric resource show dfa1b649-0333-4a70-98f6-77699df1d235 +-----------------------+-------------------------------------------------------------------+ | Field | Value | +-----------------------+-------------------------------------------------------------------+ | created_by_project_id | 0f2625947bf0433a9519ba8a29434bdf | | created_by_user_id | efeba9b14c234edbb78d0cbad397e6ed | | creator | efeba9b14c234edbb78d0cbad397e6ed:0f2625947bf0433a9519ba8a29434bdf | | ended_at | None | | id | dfa1b649-0333-4a70-98f6-77699df1d235 | | metrics | image.size: b6b99445-56ff-4184-a2f6-4c406f9ac595 | | original_resource_id | dfa1b649-0333-4a70-98f6-77699df1d235 | | project_id | 9c8b7457e8db4cbc995a767706804b70 | | revision_end | None | | revision_start | 2022-06-13T06:16:04.893399+00:00 | | started_at | 2022-06-13T06:16:04.893385+00:00 | | type | image | | user_id | None | +-----------------------+-------------------------------------------------------------------+ # イメージ サイズ データ [root@dlp ~(keystone)]# openstack metric measures show b6b99445-56ff-4184-a2f6-4c406f9ac595 +---------------------------+-------------+--------------+ | timestamp | granularity | value | +---------------------------+-------------+--------------+ | 2022-06-13T15:15:00+09:00 | 300.0 | 2226520064.0 | +---------------------------+-------------+--------------+ |
Sponsored Link |