[SOLVED] Openhab not passing data to InfluxDB

Hello All,
after a steep progress with MAX! thermostates and automation I’m running against the next wall.

Following the tutorial from @ThomDietrich

I’m getting the following error:

2019-01-31 22:23:15.027 [ERROR] [org.influxdb.impl.BatchProcessor ] - Batch could not be sent. Data will be lost
java.lang.RuntimeException: {“error”:“retention policy not found: autogen# The database URL, e.g. or .”}

at org.influxdb.impl.InfluxDBErrorHandler.handleError(InfluxDBErrorHandler.java:19) ~[296:org.openhab.persistence.influxdb:1.13.0]
at retrofit.RestAdapter$RestHandler.invoke(RestAdapter.java:242) ~[296:org.openhab.persistence.influxdb:1.13.0]
at org.influxdb.impl.$Proxy147.writePoints(Unknown Source) ~[296:org.openhab.persistence.influxdb:1.13.0]
at org.influxdb.impl.InfluxDBImpl.write(InfluxDBImpl.java:151) ~[296:org.openhab.persistence.influxdb:1.13.0]
at org.influxdb.impl.BatchProcessor.write(BatchProcessor.java:171) [296:org.openhab.persistence.influxdb:1.13.0]
at org.influxdb.impl.BatchProcessor$1.run(BatchProcessor.java:144) [296:org.openhab.persistence.influxdb:1.13.0]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]

Changing the URL in influxdb.cfg to ,localhost or the real IP didn’t change anything.
Also changing the user to admin didn’t solve the problem.

Database was created:

show databases
name: databases


Retention policy is autogen:

show retention policies
name duration shardGroupDuration replicaN default

autogen 0s 168h0m0s 1 true

Users were crated successfully:

show users
user admin

admin true
openhab false
grafana false

Thanks in Advance

I’ve just checked my config and it’s just like yours. The only thing I can suggest at this stage is a reboot.

My persistence stopped a while ago, with out me noticing and ended up fixing the problem with a simple reboot. Very frustrating to say the least as I couldn’t find a reason for the issue.

What’s in your influxdb.cfg? The error below looks like there are characters after the retentionPolicy. Does it look like this? “retentionPolicy=autogen” Anything else on that line?

Thank you. That did the trick.
Maybe I shouldn’t be sitting on the PC that late…