此内容没有您所选择的语言版本。
12.9. Configure the Compute Node
The Telemetry service monitors each node by collecting usage data from the Compute agent (
openstack-ceilometer-compute
) installed on that node. You can configure a node's Compute agent by replicating the /etc/ceilometer/ceilometer.conf
file from another host whose Telemetry components have already been configured.
You must also configure the Compute node itself to enable notifications.
Procedure 12.7. Enabling Notifications on a Compute Node
- Install openstack-ceilometer-compute, python-ceilometer and python-ceilometerclient on the node:
yum install openstack-ceilometer-compute python-ceilometer python-ceilometerclient
# yum install openstack-ceilometer-compute python-ceilometer python-ceilometerclient
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Enable auditing on the node:
openstack-config --set /etc/nova/nova.conf \ DEFAULT instance_usage_audit True
# openstack-config --set /etc/nova/nova.conf \ DEFAULT instance_usage_audit True
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Configure the audit frequency:
openstack-config --set /etc/nova/nova.conf \ DEFAULT instance_usage_audit_period hour
# openstack-config --set /etc/nova/nova.conf \ DEFAULT instance_usage_audit_period hour
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Configure what type of state changes should trigger a notification:
openstack-config --set /etc/nova/nova.conf \ DEFAULT notify_on_state_change vm_and_task_state
# openstack-config --set /etc/nova/nova.conf \ DEFAULT notify_on_state_change vm_and_task_state
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Set the node to use the correct notification drivers. Open the
/etc/nova/nova.conf
file in a text editor, and add the following lines in theDEFAULT
section:notification_driver = messagingv2 notification_driver = ceilometer.compute.nova_notifier
notification_driver = messagingv2 notification_driver = ceilometer.compute.nova_notifier
Copy to Clipboard Copied! Toggle word wrap Toggle overflow The Compute node requires two different notification drivers, which are defined using the same configuration key. You cannot useopenstack-config
to set these values. - Start the Compute agent:
systemctl start openstack-ceilometer-compute.service
# systemctl start openstack-ceilometer-compute.service
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Configure the agent to start at boot time:
systemctl enable openstack-ceilometer-compute.service
# systemctl enable openstack-ceilometer-compute.service
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Restart the
openstack-nova-compute
service to apply all changes to/etc/nova/nova.conf
:systemctl restart openstack-nova-compute.service
# systemctl restart openstack-nova-compute.service
Copy to Clipboard Copied! Toggle word wrap Toggle overflow