-
-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ZIGBEE2MQTT_AVAILABILITY not working #32
Comments
Hi @onedr0p, Weird, I've just tested and it is working (I've tested for both zigbee2mqtt 1.26.0 and 1.27.0). I do see the availability metrics: Could you please provide the following info:
Thanks |
Env: LOG_LEVEL: DEBUG
MQTT_ADDRESS: emqx.default.svc.cluster.local
MQTT_TOPIC: "zigbee2mqtt/#"
MQTT_V5_PROTOCOL: "True"
MQTT_USERNAME: username
MQTT_PASSWORD: password
PROMETHEUS_PORT: 80
PROMETHEUS_PREFIX: zigbee2mqtt_
ZIGBEE2MQTT_AVAILABILITY: "True" Zigbee2mqtt Version: 1.27.0 Logs: I can try changing to changing to |
Thanks for the details. I suspect zigbee2mqtt not exporting the availability metric for some reason. But I'll have a deeper look at the log. In the meantime, if you can extract the raw value from MQTT it would be nice. Otherwise, I may just add additional logs in the exporter to show them in debug mode. |
@onedr0p unfortunately, I am not able to reproduce your issue. Could you please run the exporter using this branch https://github.com/kpetremann/mqtt-exporter/tree/debug and provide me the logs. I have simply added the original MQTT messages in the debug log. But I don't necessarily want to merge this. |
Any chance there's a docker image of that? |
sure You'll have to set the following environment variables:
It will be pushed to Docker Hub once this GH Action is complete: https://github.com/kpetremann/mqtt-exporter/actions/runs/2935308892 |
The docker image has been pushed to Docker Hub |
On the topic of docker images would it be possible to push release tags instead of only latest? I'll try the debug image out soon. |
sure
Thanks Also can you confirm that legacy availability payload is disabled? https://www.zigbee2mqtt.io/guide/configuration/device-availability.html#availability-payload |
I set that to And what do you know with the latest latest latest version it now works :) I have no idea what happened but you did something! lol |
Oh weird ^^ the change I pushed could not have fixed that. Maybe because of a restart either of the exporter or zigbee2mqtt? Was it already set to false or did you change it recently? |
I changed it, maybe that was the fix :) |
Thanks for the debugging, I'll go ahead and close the issue! |
oh I see. I confirm this was the root cause for sure. As stated in the README, legacy mode is not supported. https://github.com/kpetremann/mqtt-exporter#zigbee2mqtt-device-availability-support Don't hesitate if you need further assistance or features. |
I got confused and thought you mean the other setting which I showed in the screenshot. |
I'll update the readme to make it clearer |
Hi 👋🏼
I deployed this and I can see metrics coming thru but it seems like
ZIGBEE2MQTT_AVAILABILITY=True
is not working. I actually still see the_state
metrics.The text was updated successfully, but these errors were encountered: