RPi2 corrupt database on a daily basis

I have been running HA on RPi2 for a couple of months and it was running fine until about a month ago and then we had a circuit breaker trip and when HA came back the DB was corrupted. Then about a week later the DB corrupted without a power cut. Now it’s getting a corrupt DB nearly once a day.

Could my micro SD card be the issue?
Any ideas?
Cheers

Could be the SD card, could also be not getting enough power from the adapter. Could be both.

1 Like

If it’s on a daily basis now, it should be easy to figure out if the sd card is the culprit.
Clone the SD card to another SD card, and see if it still corrupts daily with the other SD card. If not, it’s probably the SD. If yes, than it must be something else.

2 Likes

Cheers. Is there a best brand to use?

Buy something designed for a high write life - Samsung Endurance, WD Purple, etc. If you just buy a generic SD card, regardless of brand, they’re not intended for this kind of use and will fail on you a lot sooner.

To be clear, even the endurance cards will fail on you, it’ll just take (a lot) longer.

1 Like