I have the following set-up:
- RPi 3
- 8GB MLC microSD
- partition 1: root and the rest (read-only)
- partition 2: /var filesystem (rw)
- continuous writes to /var/logs
- system will experience unexpected sudden power offs
- no swap
Once in a while looks like that either the filesystem gets corrupted beyond fixable by
fsck, or some blocks on SD card are somehow worn out causing I/O issues, which either way results in an unbootable system.
Now the question is, if I run an intense
badblocks (like below) on such a SD card and I do not get any bad blocks reported back, would it be reasonably safe to reuse that SD card?
sudo badblocks -o ~/tmp/badblocks.list -w -s -v /dev/mmcblk0
My understanding is that the controller on the SD card is putting the worn out blocks on a black list such that they cannot be accessed from the OS anymore. In that case we have basically taken out the bad tooth and we should be able to keep using it.
The only thing I can think of that would stop me from reusing the SD card is that since there has been at least one worn out block, it means that most probably more worn out blocks will pop up soon. This is because if I am right the SD card controller is supposed to try to write to blocks evenly. Which means that other working blocks on the SD card are probably close to the end of their lives.
Is this a correct assertion?