New OH 5.1.1 on Ubuntu 24.04 cant install InfluxDb post install

  • Platform information:

    • Hardware: Virtual Box 4Gb 4Core
    • Ubuntu 24.04
    • Java Runtime Environment: openjdk 21
    • openHab 5.1.1
  • Issue of the topic: Clean install, Settings→ Persistence → Install more addons → Select InfluxDb

InfluxDb appears installed in add on store, but doesn’t appear in the persistence section.

I’ve restarted Open Hab and the machine but Influx still doesn’t appear.

Tried installing MongoDb and it’s fine

Any suggestions?

Logs?

Something is going wrong and when something goes wrong there is almost always something written to the logs.

Hi, sorry of course that would help !!!

Now I have checked the logs myself it appears InfludDb doesn’t work with OH5. According to Ai it’s a well known incompatability.
Initially it was looking for a configuration file and when given one manually it seemed happier. Initially it just failed due to no credentials.
The error log is huge, full of Java errors - at least 100 lines, I stopped looking when I saw the total.

I think maybe I revert to OH4 maybe ?

AI is making stuff up. InfluxDB should work just fine with OH and it’s probably our third most used database (behind rrd4j and mapdb).

Seeing the actual logs would be helpful.

Use code fences.

```
code goes here
```

These are the errors in order they appear:

```

Level: ERROR
Logger Class:
org.openhab.persistence.influxdb.InfluxDBPersistenceService

Message:
bundle org.openhab.persistence.influxdb:5.1.1 (305)[org.openhab.persistence.influxdb.InfluxDBPersistenceService(394)] : Error during instantiation of the implementation object

=========

Level: WARN
Logger Class:
org.openhab.core.persistence.internal.PersistenceManagerImpl

Message:

bundle org.openhab.core.persistence:5.1.1 (220)[org.openhab.core.persistence.internal.PersistenceManagerImpl(260)] : Could not get service from ref {org.openhab.core.persistence.PersistenceService, org.openhab.core.persistence.QueryablePersistenceService}={service.id=568, service.bundleid=305, service.scope=bundle, osgi.ds.satisfying.condition.target=(osgi.condition.id=true), service.config.label=InfluxDB Persistence Service, component.name=org.openhab.persistence.influxdb.InfluxDBPersistenceService, component.id=394, service.config.factory=false, service.config.category=persistence, service.pid=org.openhab.influxdb, service.config.description.uri=persistence:influxdb}

Level: WARN
Logger Class
org.openhab.persistence.influxdb.internal.InfluxDBConfiguration

Message
InfluxDB configuration isn’t valid. Addon won’t work: No credentials

====================

```

I have created a config file that put in dummy credentials but it just removed that one error, the others remained. I assume when it works normally the credentials could be added through the UI

Problem solved.

put false configuration in the .cfg and it now appears in the UI. I must have made a mistake first time.

My Solution:

file at:

/etc/openhab/services/influxdb.cfg

Replace contents with:

version=V1
url=http://localhost:8086
user=openhab
password=yourpassword
db=openhab
retentionPolicy=autogen