Normal amount of data? Is 37GB for one year normal?

Just recently our OpenEMS wasn’t able to save any historic data anymore as the disk was full. On inspecting the issue, I recognized that the influxDB data dir raised to 37 GB after one year of running the system with currently approx. 80 configured OpenEMS-components.

Is this to be expected, or should we double check the configuration? E.g., we have debug log enabled, I could imagine that this will create some amount of data, ending up in the influxDB…?

Is there a script or documentation how to purge or prune the influxDB of an OpenEMS system?

37 GB can be plausible with 80 components if many channels are persisted at high resolution; it is not proof of a fault. Debug logging normally goes to log files, not InfluxDB, unless you added a custom Influx sink. Check which channels have persistence enabled, their cycle time, and the InfluxDB retention policy/shard duration. For cleanup, take a backup first, then use a shorter retention policy or targeted DELETE/DROP SERIES rather than deleting the data directory. Also inspect measurement and series cardinality to find noisy channels.

Thanks for your reply @digiliobutzer3285.

I’m not exactly sure if I checked all this the correct way: I currently have (among others) following settings configured:

(IMHO maybe relevant) OpenEMS component settings

In other components I didn’t find any channel that looked related to persistence to me.

org.apache.felix.scr.ScrService

  • ds.loglevel Debug

Controller.Debug.Log

  • enabled Yes

Core.Cycle

  • cycleTime 1000
  • logVerbosity COMPONENTS

Timedata.InfluxDB

  • noOfCycles 1
  • maxQueueSize 5000
  • persistencePriority VERY_LOW

InfluxDB

Using the influx cli:

# influx bucket list
ID	Name		Retention	Shard group duration	Organization ID	Schema Type
123	_monitoring	168h0m0s	24h0m0s				abc		implicit
456	_tasks		72h0m0s		24h0m0s				abc		implicit
789	openems		infinite	168h0m0s			abc		implicit
# influx task list
ID	Name	Organization ID	Organization	Status	Every	Cron	ScriptID

Are above settings adequate for a production system? I’m a bit puzzled about the InfluxDB settings: It seems no task is defined and only one openems bucket is used. If I understand downsampling within InfluxDB correct, two buckets and a task would be needed. Thus I’m wondering how downsampling works within OpenEMS, or what other concept is used to prevent rapid data growth within OpenEMS?