[openstack-dev] [vitrage] Collectd - to - Vitrage setup issues

Afek, Ifat (Nokia - IL/Kfar Sava) ifat.afek at nokia.com
Mon Aug 28 13:42:30 UTC 2017


Hi Greg,

I’m less familiar with the collectd configuration and the events that it sends.

Regarding the collectd_conf.yaml, it is definitely missing. You should add a /etc/vitrage/collectd_conf.yaml file that looks like that:

collectd:
- collectd_host: <collectd resource name>
   type: <openstack resource type, e.g. nova.host>
   name: <openstack resource name, e.g. host1>
- collectd_host: …


This file maps a Collectd resource to the corresponding resource in OpenStack. Only resources that are listed in this file will have their alarms imported to Vitrage.

Next, you should add a reference to this file in /etc/vitrage/vitrage.conf:

[collectd]
config_file = /etc/vitrage/collectd_conf.yaml

Then you should restart vitrage-graph.

Let me know if it helped,
Ifat.


From: "Waines, Greg" <Greg.Waines at windriver.com>
Date: Wednesday, 23 August 2017 at 21:19

I am trying to get collectd to report some alarms to vitrage in a devstack setup,

I am using a devstack created on a late version of ocata.
And my devstack with vitrage appears to be working ok otherwise;
e.g.  I can create VMs, and raise fake alarms using “vitrage event post -type=compute.host.down ...” or with “aodh alarm create ... resource_id=instance-uuid” ... and they get reported fine in vitrage.

UNFORTUNATELY not seeing anything in vitrage from collectd, and
                          don’t believe I’m seeing anything even from collectd, for example from the syslog output plugin.

I’ve attached the following files:   ( not sure if these get distributed on mailing list )
·         /etc/collectd/collectd.conf       <-- do these look ok ?
·         /etc/vitrage/vitrage.conf          <-- do these look ok ?
·         /var/log/syslog                 ... around the time when I updated collectd.conf and vitrage.conf and restarted collectd and vitrage-graph
o    QUESTIONS
•  NOTE THE FOLLOWING ERRORS IN THE SYSLOG FILE ... where do I get the collectd_conf.yaml file from ?  Can’t see it in the devstack files for vitrage.
·         Aug 23 14:09:31 localhost vitrage-graph[25962]: 2017-08-23 14:09:31.039 25962 ERROR vitrage.utils.file [-] File doesn't exist: /etc/vitrage/collectd_conf.yaml.
·         Aug 23 14:09:31 localhost vitrage-graph[25962]: 2017-08-23 14:09:31.040 25962 ERROR vitrage.datasources.collectd.driver [-] failed in init 'NoneType' object has no attribute '__getitem__' : TypeError: 'NoneType' object has no attribute '__getitem__'
·         Aug 23 14:09:31 localhost vitrage-graph[25962]: 2017-08-23 14:09:31.040 25962 ERROR vitrage.datasources.collectd.driver Traceback (most recent call last):
·         Aug 23 14:09:31 localhost vitrage-graph[25962]: 2017-08-23 14:09:31.040 25962 ERROR vitrage.datasources.collectd.driver   File "/opt/stack/vitrage/vitrage/datasources/collectd/driver.py", line 65, in _configuration_mapping
·         Aug 23 14:09:31 localhost vitrage-graph[25962]: 2017-08-23 14:09:31.040 25962 ERROR vitrage.datasources.collectd.driver     collectd_config_elements = collectd_config[COLLECTD_DATASOURCE]
·         Aug 23 14:09:31 localhost vitrage-graph[25962]: 2017-08-23 14:09:31.040 25962 ERROR vitrage.datasources.collectd.driver TypeError: 'NoneType' object has no attribute '__getitem__'
·         Aug 23 14:09:31 localhost vitrage-graph[25962]: 2017-08-23 14:09:31.040 25962 ERROR vitrage.datasources.collectd.driver
•
•  IT DOESN”T SEEM LIKE collectd is actually getting any events anyways ... shouldn’t I see some collectd events being reported in /var/log/syslog from some of the monitoring plugins that are loaded ?
·         gregs-air:collectd-info gregwaines$ fgrep "localhost collectd" syslog
·         Aug 23 13:56:07 localhost collectd[23267]: supervised by systemd, will signal readyness
·         Aug 23 13:56:07 localhost collectd[23267]: Initialization complete, entering read-loop.
·         Aug 23 13:56:07 localhost collectd[23267]: rrdtool plugin: Adjusting "RandomTimeout" to 0.000 seconds.
·         Aug 23 14:09:05 localhost collectd[23267]: Exiting normally.
·         Aug 23 14:09:05 localhost collectd[23267]: collectd: Stopping 5 read threads.
·         Aug 23 14:09:05 localhost collectd[23267]: rrdtool plugin: Shutting down the queue thread.
·         Aug 23 14:09:05 localhost collectd[23267]: collectd: Stopping 5 write threads.
·         Aug 23 14:09:07 localhost collectd[25824]: supervised by systemd, will signal readyness
·         Aug 23 14:09:07 localhost collectd[25824]: Initialization complete, entering read-loop.
·         Aug 23 14:09:07 localhost collectd[25824]: rrdtool plugin: Adjusting "RandomTimeout" to 0.000 seconds.
·
·         /etc/vitrage/templates/host_down_scenarios.yaml
·         /etc/vitrage/templates/host_high_cpu_load_scenarios.yaml
o    Am I suppose to have some templates that are specific to the collectd events/alarms that are being reported to vitrage ?

Any other suggestions on things to look at in order to understand what’s wrong ?

Greg.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20170828/fe03fb07/attachment.html>


More information about the OpenStack-dev mailing list