diff --git a/devstack/libs/collectd b/devstack/libs/collectd index 1f55c42..3004d99 100644 --- a/devstack/libs/collectd +++ b/devstack/libs/collectd @@ -154,6 +154,21 @@ function adapt_collectd_conf { config_custom_units "gnocchi" "$COLLECTD_GNOCCHI_UNITS" fi + # configure collectd-aodh plugin + if [[ "$COLLECTD_AODH_ENABLED" == "True" ]]; then + + sudo cp $COLLECTD_CEILOMETER_DIR/etc/collectd.conf.d/collectd-aodh-plugin.conf $COLLECTD_CONF_DIR/ + + # Configure collectd-aodh-plugin.conf + sudo sed -i 's|ModulePath.*$|ModulePath "'$COLLECTD_CEILOMETER_DIR'"|g' $COLLECTD_CONF_DIR/collectd-aodh-plugin.conf + sudo sed -i 's|VERBOSE.*$|VERBOSE '$COLLECTD_CEILOMETER_VERBOSE'|g' $COLLECTD_CONF_DIR/collectd-aodh-plugin.conf + sudo sed -i 's|OS_AUTH_URL.*$|OS_AUTH_URL "'$OS_AUTH_URL'"|g' $COLLECTD_CONF_DIR/collectd-aodh-plugin.conf + sudo sed -i 's|CEILOMETER_URL_TYPE.*$|CEILOMETER_URL_TYPE "'$CEILOMETER_URL_TYPE'"|g' $COLLECTD_CONF_DIR/collectd-aodh-plugin.conf + sudo sed -i 's|CEILOMETER_TIMEOUT.*$|CEILOMETER_TIMEOUT "'$CEILOMETER_TIMEOUT'"|g' $COLLECTD_CONF_DIR/collectd-aodh-plugin.conf + sudo sed -i 's|OS_PASSWORD.*$|OS_PASSWORD "'$SERVICE_PASSWORD'"|g' $COLLECTD_CONF_DIR/collectd-aodh-plugin.conf + sudo sed -i 's|OS_TENANT_NAME.*$|OS_TENANT_NAME "'$SERVICE_TENANT_NAME'"|g' $COLLECTD_CONF_DIR/collectd-aodh-plugin.conf + fi + # Configure collectd logfile plugin if [ -n $COLLECTD_LOG_FILE ]; then touch $COLLECTD_LOG_FILE diff --git a/devstack/settings b/devstack/settings index 14c9fc1..80ce6e3 100644 --- a/devstack/settings +++ b/devstack/settings @@ -15,6 +15,7 @@ COLLECTD_CEILOMETER_VERBOSE=$(trueorfalse False COLLECTD_CEILOMETER_VERBOSE) COLLECTD_CEILOMETER_ENABLED=$(trueorfalse False COLLECTD_CEILOMETER_ENABLED) COLLECTD_GNOCCHI_ENABLED=$(trueorfalse True COLLECTD_GNOCCHI_ENABLED) +COLLECTD_AODH_ENABLED=$(trueorfalse False COLLECTD_AODH_ENABLED) # Configurations for Collectd LogFile plugin COLLECTD_LOG_FILE=${COLLECTD_LOG_FILE:-$LOGDIR/collectd.log} diff --git a/doc/source/devstackGSG.rst b/doc/source/devstackGSG.rst index 56e753c..fbf599e 100644 --- a/doc/source/devstackGSG.rst +++ b/doc/source/devstackGSG.rst @@ -92,3 +92,19 @@ To deploy with gnocchi using devstack, add the following to you local.conf: enable_service gnocchi-api,gnocchi-metricd,gnocchi-statsd GNOCCHI_USE_KEYSTONE=True COLLECTD_GNOCCHI_ENABLED=True + +Aodh +==== + +Aodh is an alarming service that allows an alarm to be created and/or updated +if there is something unusual happening with the system. When this service is +enabled via the collectd-ceilometer-plugin, it allows alarms to be +created/updated for all notifications sent from collectd. All notifications +sent from collectd are configured as event alarms in Aodh. +To enable aodh with collectd, add the following to your local.conf: + + #AODH + enable_plugin aodh https://git.openstack.org/openstack/aodh + + enable_plugin collectd-ceilometer-plugin http://github.com/openstack/collectd-ceilometer-plugin + COLLECTD_AODH_ENABLED=True diff --git a/doc/source/usage.rst b/doc/source/usage.rst index d4fc018..7252a42 100644 --- a/doc/source/usage.rst +++ b/doc/source/usage.rst @@ -95,6 +95,12 @@ COLLECTD_GNOCCHI_ENABLED Default: True +COLLECTD_AODH_ENABLED + (True|False) Toggles whether collectd-aodh-plugin is enabled. + + Default: False + + COLLECTD_INSTALL_TYPE (source|binary) Specify whether the collectd installation should use the package manager or install from source. diff --git a/releasenotes/notes/deploy-collectd-aodh-2287747b5917abfe.yaml b/releasenotes/notes/deploy-collectd-aodh-2287747b5917abfe.yaml new file mode 100644 index 0000000..32b5fa9 --- /dev/null +++ b/releasenotes/notes/deploy-collectd-aodh-2287747b5917abfe.yaml @@ -0,0 +1,7 @@ +--- +features: + - Created deployment code for the collectd-aodh-plugin. This + feature is not enabled by default, but instructions are also + provided for enabling this feature. Once enabled, when a + notification is registered by collectd a corresponding event + alarm is created by aodh.