michbeck100 / pv-monitoring

Contains configuration and Grafana dashboard for monitoring PV inverters
Apache License 2.0
43 stars 11 forks source link

image platform issue #1

Closed ericbodden closed 1 year ago

ericbodden commented 1 year ago

Hello. I am new to docker but I would really like to try out this project because we got a new Sungrow inverter and the app really seems to display implausible values.

I got pretty far with the docker compose up -d command after having set the monitoring network to "not external" in the yml file.

Because I am seeking to deploy this on a mac, I then next added platform: linux/amd64 to the different image configurations, however, for one image I am then getting this error message:

Error response from daemon: image with reference iobroker/iobroker:latest-v7 was found but does not match the specified platform: wanted linux/amd64, actual: linux/arm64

Is there any way in which I can fix this myself?

michbeck100 commented 1 year ago

I assume your Mac is Intel-based?

michbeck100 commented 1 year ago

Apart from that I think you don’t have to set platform at all. Docker chooses the platform automatically.

ericbodden commented 1 year ago

Hello. No I have a silicon-based Mac.

When I do not set the platform, I see a bunch of these errors, they all seem to be for "renderer":

⠴ renderer The requested image's platform (linux/arm) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested 0.0s

ericbodden commented 1 year ago

Hmm, I am not sure how but I now got this to run! Yet, the visualization shows me "No data". I guess I need to set the HOST variable to the inverter's host name or IP address? Is there anything else I need to configure?

michbeck100 commented 1 year ago

No, just use HOST if you also use traefik. For me it's fritz.box. So in the end my Grafana would be available at Grafana.fritz.box. You will need a DNS rewrite for this, too.

I will look into the renderer problem, too.

michbeck100 commented 1 year ago

The inverter ip must be set in https://github.com/michbeck100/pv-monitoring/blob/main/sungather%2Fconfig.yaml as described here: https://github.com/michbeck100/pv-monitoring#sungather. Please read this carefully: https://github.com/michbeck100/pv-monitoring/blob/main/README.md

michbeck100 commented 1 year ago

I replaced the renderer image with my own build. This build is for linux/amd64, linux/arm64 and linux/arm/v7. Please let me know if that works for you

ericbodden commented 1 year ago

Yes, thanks, that seems to have done the trick! Also thanks for pointing me to the config file again, I now got the basic functionality up and running. That was really easier than expected, thanks a lot!

One more very general question: will I need to keep this running at all times in order to later be able to browse historical data or does the visualization pull historical data from the inverter as requested?

ericbodden commented 1 year ago

Okay after some investigation I find that some of the charts still remain empty, I wonder why, see this image...

image

The same is true for some more charts further down. The ones at the top work. Maybe I should mention that I have no wallbox. Not sure if that is part of the problem.

Also, under "Ersparnis- und Einnahmenrechner" I still see "No data". I have set the two constants strompreis and verguetung in pv-monitoring.json.

At the bottom, my system state is shown as "unknown".

michbeck100 commented 1 year ago

Which inverter do you have?

ericbodden commented 1 year ago

It's an SH10RT

michbeck100 commented 1 year ago

Hmm, i have the same. I will send you my config once I’m back home

michbeck100 commented 1 year ago

That's my config in sungather:

inverter:
  host: <inverter-ip>                      # [Required] IP Address of the Inverter or Dongle
  port: 502                               # [Optional] Default for modbus is 502, for http is 8082
  timeout: 5                              # [Optional] Default is 10, how long to wait for a connection
  retries: 3                              # [Optional] Default is 3, how many times to retry if connection fails
  slave: 0x01                             # [Optional] Default is 0x01
  scan_interval: 10                       # [Optional] Default is 30
  connection: modbus                      # [Required] options: modbus, sungrow, http
  # model: "SH10RT"                         # [Optional] This is autodetected on startup, only needed if detection issues or for testing
                                            # See model list here: https://github.com/bohdan-s/SunGather#supported
  smart_meter: False                       # [Optional] Default is False, Set to true if inverter supports reading grind / house consumption
  use_local_time: True                    # [Optional] Default False, Uses Inventer time, if true it uses PC time when updating timestamps (e.g. PVOutput)
  # log_console: INFO                       # [Optional] Default is WARNING, Options: DEBUG, INFO, WARNING, ERROR
  # log_file: INFO                           # [Optional] Default is OFF, Options: OFF, DEBUG, INFO, WARNING, ERROR
  level: 2                                # [Optional] Set the amount of information to gather

As you can see for me even the model auto detection works.

From the screenshot I would say you have used a time range that's not in the past. You can tell that its working because the legend shows values.

ericbodden commented 1 year ago

Thanks! I will be returning home on Wednesday, will tr this out then.

ericbodden commented 1 year ago

This is working now, thanks! I think the important change was for the connection (from sungrow to modbus). The "Ersparnis- und Einnahmenrechner" is still showing "no data", though. Any thoughts on this?

Also the state is still shown as "unknown".

michbeck100 commented 1 year ago

Could you open a new issue on this? And please provide some additional information, like configs etc. I will close this issue as the original problem is resolved