system_sensors icon indicating copy to clipboard operation
system_sensors copied to clipboard

Getting state unavailable?

Open brynyneuadd opened this issue 2 years ago • 8 comments

Hi,

Installed this and all appears to be working, except all my Home Assistant entities are listed as 'unavailable' - any idea what this means?

brynyneuadd avatar Jun 04 '22 06:06 brynyneuadd

I have the same problem!

JAnslinger avatar Aug 11 '22 13:08 JAnslinger

Have you checked what is being published to MQTT? I had this when there was two instances running, one pubishing over the other.

the-jeffski avatar Aug 14 '22 09:08 the-jeffski

Hello, have the same problem. How to get rid of it? How to figure out if there are two instances? Thanks

Hamudulu avatar Feb 13 '23 15:02 Hamudulu

Simplest is run ps | grep "system_sensors*"

the-jeffski avatar Feb 14 '23 11:02 the-jeffski

Thanks, and if there is nothing shown then nothing is running? Im struggling with point 7 and the following points. After did point 7 the sensor are visible in HA but after closing the terminal they are unavailable. Strange.

Hamudulu avatar Feb 14 '23 11:02 Hamudulu

Ah, so it not running. When you close the terminal it will quit as its running from there. You need to enable the service in part 8 for it to run in the background.

the-jeffski avatar Feb 14 '23 11:02 the-jeffski

yes, of course, I tried. that's the message I got: `● system.sensors.service - Python based System Sensor Service for MQTT Loaded: loaded (/etc/systemd/system/system.sensors.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Tue 2023-02-14 12:53:10 CET; 9s ago Process: 19700 ExecStart=/usr/bin/python3 /home/pi/system_sensors/src/system_sensors.py /home/> (code=exited, status=1/FAILURE) Main PID: 19700 (code=exited, status=1/FAILURE) CPU: 479ms

Feb 14 12:53:09 pi systemd[1]: Started Python based System Sensor Service for MQTT. Feb 14 12:53:10 pi python3[19700]: Traceback (most recent call last): Feb 14 12:53:10 pi python3[19700]: File "/home/pi/system_sensors/src/system_sensors.py", line 13, in Feb 14 12:53:10 pi python3[19700]: from rpi_bad_power import new_under_voltage Feb 14 12:53:10 pi python3[19700]: ModuleNotFoundError: No module named 'rpi_bad_power' Feb 14 12:53:10 pi systemd[1]: system.sensors.service: Main process exited, code=exited, status=1/FAILURE Feb 14 12:53:10 pi systemd[1]: system.sensors.service: Failed with result 'exit-code'.`

Hamudulu avatar Feb 14 '23 11:02 Hamudulu

Try setting power_status: false in the config.

the-jeffski avatar Feb 25 '23 20:02 the-jeffski