#Where can I find a history of when HA has been restarted?

1 messages · Page 1 of 1 (latest)

frigid oxide
#

This is for collecting information while troubleshooting; I'm currently looking for a pattern in an intermittent ZHA issue.
I can probably find a log of when the Docker container was restarted, but I don't think that would include the times that HA was told to restart from the web UI. home-assistant.log only appears to go back to the last restart, and home-assistant.log.1 the restart before that.
On a related note, how do I make it keep more than one previous log?

raw acorn
#

You can use sensor.uptime which has a state set to the last time HA started. Otherwise, you could create a template sensor that triggers on the HA shutdown event and set it's state to the time HA stopped.

#

And no, you can't keep previous logs (unless you do something with Python or something that gets called during the HA shutdown event).

severe roost
#

HAOS keeps lots of old logs via journald though.