[SOLVED] Can't configure items in grafana through influxdb.persist ( not refreshing the list)

Release = Raspbian GNU/Linux 8 (jessie)
Kernel = Linux 4.9.35-v7+
Platform = Raspberry Pi 3 Model B Rev 1.2
openHAB 2.5.0~M2-1 (Milestone Build)

I run grafana over a year now. I tried to configure items through influxdb.persist but the list doesn’t refresh on grafana when I create new dashboard. I delete items and add items but nthing change. Still have the first configuration.

2019-12-23 10:49:36.539 [INFO ] [el.core.internal.ModelRepositoryImpl] - Refreshing model ‘influxdb.persist’
When I save the file, buτ nothing change on the list in grafana interface.

Strategies {

    everyMinute : "0 * * * * ?"

    everyHour   : "0 0 * * * ?"

    everyDay    : "0 0 0 * * ?"

}

Items {

livRoom_sensor_tm : strategy = everyChange 

pcroom_sensor_tm : strategy = everyChange 

kitchen_sensor_tm : strategy = everyChange
}

With your persistence settings in OpenHAB you yust configure what is sent over to influxDB. That has nothing to do with grafana. Grafana connects to influxDB (if you configured it that way) and reads data from there. I’m not quite sure what you expect to happen in in grafana. You have to create a panel in your dashboard an query your items.

What do you mean by “I delete items and add items but nthing change”? If you add an item in OpenHAB it only get’s written into influxDB when you have assigned a strategy for it. So far you only have strategies for 3 items, so only those 3 will land in your influxDB.

thnx .
I understand now better.
Now… How can I add items here?

You need to restart openHAB after modifying a *.persist file to take effect

I tried this . Nothing change.Any idea?

In the drop down list in grafana not all items will appear but if you type the first letters of the item name it should appear. It does that on my set-up.

You don’t add items here. These is a list of items in your influxDB. To get your items into influxdb you have to add them to your strategies (in influxdb.persis unter “Items”). Depending on what you set as strategy it will take some time for OpenHAB to write the values to influxDB and for the items to appeat in your list. Keep an eye on your logs if you get errors.

That’s an important thing, the OH persistence will write to db only when a defined item’s value has changed. If you want to graph an item, what only changes rarely, the best way if you define more than one strategy in the persist file. For example everyChange,everyHour. In this case, OH will write to the db in every hour, independently that, the item changed or not int that timeframe. I usually use “strategy = everyChange, everyHour” stanza.

Also the change is not instantaneous. So it need a restart and some time to load the data.
Thnx @vzorglub. :slight_smile: