Every other day graph stop (InfluxDB ?) - any idea why?

I’m using basic graph to show my influxDB data in various ways. every few days it stops working, only reboot does reset and all works again, the rest seems to not suffer from this. of course in that time no new values are stored in influxDB.

Im on Raspi4 with OH4 M3

image

I found the following error in the log, so my guess is that the link to influxDB is lost.
Is there any known issue about influxDB. im on version 1.8.6.

Thanks a lot for looking into this, Kind Regards Norbert

2023-06-20 11:09:04.050 [WARN ] [ab.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.openhab.core.io.monitor.internal.EventLogger@1b3d7f3' takes more than 5000ms.
2023-06-20 11:09:12.367 [WARN ] [mmon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception:
org.influxdb.InfluxDBIOException: java.net.SocketTimeoutException: timeout
        at org.influxdb.impl.InfluxDBImpl.execute(InfluxDBImpl.java:841) ~[?:?]
        at org.influxdb.impl.InfluxDBImpl.write(InfluxDBImpl.java:470) ~[?:?]
        at org.openhab.persistence.influxdb.internal.influx1.InfluxDB1RepositoryImpl.write(InfluxDB1RepositoryImpl.java:132) ~[?:?]
        at org.openhab.persistence.influxdb.InfluxDBPersistenceService.commit(InfluxDBPersistenceService.java:285) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[?:?]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
        at java.lang.Thread.run(Thread.java:833) ~[?:?]
Caused by: java.net.SocketTimeoutException: timeout
        at okio.Okio$4.newTimeoutException(Okio.java:232) ~[?:?]
        at okio.AsyncTimeout.exit(AsyncTimeout.java:276) ~[?:?]
        at okio.AsyncTimeout$2.read(AsyncTimeout.java:243) ~[?:?]
        at okio.RealBufferedSource.indexOf(RealBufferedSource.java:358) ~[?:?]
        at okio.RealBufferedSource.readUtf8LineStrict(RealBufferedSource.java:230) ~[?:?]
        at okhttp3.internal.http1.Http1ExchangeCodec.readHeaderLine(Http1ExchangeCodec.java:242) ~[?:?]
        at okhttp3.internal.http1.Http1ExchangeCodec.readResponseHeaders(Http1ExchangeCodec.java:213) ~[?:?]
        at okhttp3.internal.connection.Exchange.readResponseHeaders(Exchange.java:115) ~[?:?]
        at okhttp3.internal.http.CallServerInterceptor.intercept(CallServerInterceptor.java:94) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.java:43) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:117) ~[?:?]
        at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.java:94) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:117) ~[?:?]
        at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.java:93) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.java:88) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:117) ~[?:?]
        at org.influxdb.impl.BasicAuthInterceptor.intercept(BasicAuthInterceptor.java:22) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:117) ~[?:?]
        at org.influxdb.impl.GzipRequestInterceptor.intercept(GzipRequestInterceptor.java:42) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:117) ~[?:?]
        at okhttp3.logging.HttpLoggingInterceptor.intercept(HttpLoggingInterceptor.java:152) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:142) ~[?:?]
        at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:117) ~[?:?]
        at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:229) ~[?:?]
        at okhttp3.RealCall.execute(RealCall.java:81) ~[?:?]
        at retrofit2.OkHttpCall.execute(OkHttpCall.java:188) ~[?:?]
        at org.influxdb.impl.InfluxDBImpl.execute(InfluxDBImpl.java:829) ~[?:?]
        ... 9 more

What does “sudo systemctl status influxd” show? You can get some info with that command.

● influxdb.service - InfluxDB is an open-source, distributed, time series database
     Loaded: loaded (/lib/systemd/system/influxdb.service; enabled; vendor preset: enabled)
     Active: active (running) since Sat 2023-03-25 11:31:33 PDT; 2 months 25 days ago
       Docs: https://docs.influxdata.com/influxdb/
   Main PID: 594 (influxd)
      Tasks: 10 (limit: 4177)
     Memory: 461.0M
        CPU: 2d 16h 10min 37.263s
     CGroup: /system.slice/influxdb.service
             └─594 /usr/bin/influxd -config /etc/influxdb/influxdb.conf

is that already the end of the error message or are the following lines describing the problem more in detail e.g. something like

java.lang.OutOfMemoryError: unable to create native thread: possibly out of memory or process/resource limits reached

Service is running…

> pi@SmartPi:~ $ sudo systemctl status influxd
> ● influxdb.service - InfluxDB is an open-source, distributed, time series database
>      Loaded: loaded (/lib/systemd/system/influxdb.service; enabled; vendor preset: enabled)
>      Active: active (running) since Tue 2023-06-20 16:17:11 CEST; 1h 18min ago
>        Docs: https://docs.influxdata.com/influxdb/
>    Main PID: 4668 (influxd)
>       Tasks: 15 (limit: 3933)
>         CPU: 6min 33.900s
>      CGroup: /system.slice/influxdb.service
>              └─4668 /usr/bin/influxd -config /etc/influxdb/influxdb.conf

sorry, the log shows only “…9 more”. so its not listed what else happened. not sure if the log level can help here…

Can it be that write happens when influx is doing its compaction/cleanups making answer slow and reach client timeout? And that timeout breaks writer task on OH end?

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.