Getting a ton of these errors in the log and it seems to be DB related:
[parameters: ('state_changed', '{"entity_id": "sensor.load_15m", "old_state": {"entity_id": "sensor.load_15m", "state": "0.82", "attributes": {"unit_of_measurement": " ", "friendly_ ... (446 characters truncated) ... :00", "last_updated": "2019-11-06T00:44:07.063591+00:00", "context": {"id": "118c1332595f4d089c065b0f29fedac8", "parent_id": null, "user_id": null}}}', 'LOCAL', '2019-11-06 00:44:07.063652', '2019-11-06 00:44:07.142478', '118c1332595f4d089c065b0f29fedac8', None)]
(Background on this error at: http://sqlalche.me/e/4xp6)
2019-11-06 00:44:07 ERROR (Recorder) [homeassistant.components.recorder.util] Error executing query: (sqlite3.DatabaseError) database disk image is malformed
[SQL: INSERT INTO events (event_type, event_data, origin, time_fired, created, context_id, context_user_id) VALUES (?, ?, ?, ?, ?, ?, ?)]
[parameters: ('state_changed', '{"entity_id": "sensor.memory_free", "old_state": {"entity_id": "sensor.memory_free", "state": "589.0", "attributes": {"unit_of_measurement": "MiB", " ... (463 characters truncated) ... :00", "last_updated": "2019-11-06T00:44:07.090358+00:00", "context": {"id": "62b916281d424a85af2c06840abec9c2", "parent_id": null, "user_id": null}}}', 'LOCAL', '2019-11-06 00:44:07.090478', '2019-11-06 00:44:07.164388', '62b916281d424a85af2c06840abec9c2', None)]
(Background on this error at: http://sqlalche.me/e/4xp6)
2019-11-06 00:44:07 ERROR (Recorder) [homeassistant.components.recorder] Error saving event: <Event state_changed[L]: entity_id=sensor.memory_free, old_state=<state sensor.memory_free=589.0; unit_of_measurement=MiB, friendly_name=Memory free, icon=mdi:memory @ 2019-11-06T00:43:36.092465+00:00>, new_state=<state sensor.memory_free=592.4; unit_of_measurement=MiB, friendly_name=Memory free, icon=mdi:memory @ 2019-11-06T00:44:07.090358+00:00>>
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1249, in _execute_context
cursor, statement, parameters, context
File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/default.py", line 580, in do_execute
cursor.execute(statement, parameters)
sqlite3.DatabaseError: database disk image is malformed
How can I resolve them?