[collectd] Newbie questions: type_instance

Alexey Lobanov A.Lobanov at gctrials.com
Mon Apr 26 10:08:44 CEST 2010


Hello all.

I am writing a local plugin for Collectd, to make fancy display of 
ambient conditions in monitored storage area. The monitored parameters 
fit to standard types.db: just two "temperature" sensors in Celsius 
("floor" and "ceiling") and one relative humidity sensor.

Everything works fine with this self-written plugin (based on 
examples/myplugin.c) while I try to collect and display only one 
temperature value. And one humidity.

The question is how to deal with two (or more) same-type parameters in 
one plugin and one colection.cgi web-page. I.e, two temperatures. In one 
graph with two colors, or in two graphs at a same page.

I have meditated with the "df.c" code and the corresponding part of 
collection.cgi, with no success: as soon as I start to submit non-empty 
"type_instance", collection.cgi displays a single (first) recorded value 
only in fresh-created "temperature-floor.rrd". I even do not quote my 
code for detailed questions, because this had been written without 
proper understanding.


Now the question. Can anyone point me at a some kind of *advanced* 
plugin HOWTO decribing data submission in plugin and corresponding data 
interpretation in collection.cgi? A piece of commented code can be a 
solution.

Alexey



More information about the collectd mailing list