Monitor USB keydrive for errors?
Hello,
I use a USB keydrive to run a Linux appliance. Is there a way to monitor read/write errors and receive an e-mail, so that I know it's time to get a new keydrive? Code:
~# lshw -short |
I assume that your exceeding the drives write cycle limit versus file system corruption or other errors. From my experience they either become read only or just die and not something that gets worse over time. How often do your drives fail?
Unfortunately, flash drives typically do not have SMART capabilities or most USB bridges do not pass those commands so there isn't any good method as far as I know to determine remaining life like a SSD. In addition cheap flash drives only have about 1000 cycle write limit or so which means if your writing/deleting lots of data you could wear one out fairly quickly. |
I've only had one fail so far. When it happened, it randomly turned off the computer, at least once, maybe twice (?kernel panic???, but it failed to a power OFF state). After which it doesn't even get recognized.
Typically I use a stick as my main OS drive for about six months, then I just swap in a new one out of paranoia. I tend to use 32GB sticks and by six months, I have enough cruft to need more space via a new stick and a minimal install. I've had like 3x SDHC cards fail so far, mostly to read-only states. No real errors per say, just random oddness. The worst in the SDHC category failed after only 4 hours of use. But MOST of my flash devices are still functional. I tend to dd zeros to the devices and use cmp to check that it is zeros. If it fails that at anything other than out of space / end of device, then I know it has failed. |
I get the feeling that some usb drives do support smart.
However you are simply waiting for it's death. Might consider a usb mechanical/ssd drive instead. |
Well, I had that issue with Ubuntu, the clear reinstallation of OS was the very thing resolved it
|
Quote:
Quote:
At worst, it only takes about 30mn to install Debian on a new USB stick and restore data, though. |
As an alternative to a USB stick, I could use a small SSD. I assume they are more reliable than USB keydrives.
The device has a regular, full-size USB port, and an SD card port. Based on experience, which port do you suggest I use to connect the SSD? Thank you. |
I'd think that good ssd's are way more reliable than a usb flash drive.
Not sure I've seen a ssd that connects to a sd card port. You may mean a sd card that could be as good or better than a usb flash on some highest quality ones. An external mechanical or ssd would be usb (or fireware or esata or ssd or nas or iscsi or .....) |
There are SSD-to-(USB|SD) adaptors.
Before ordering, I need to know which you would recommend, considering this is just a tiny, home appliance to handle a couple of brochure web sites. -- Edit: According to Google, SSD-to-USB seems more common. |
All times are GMT -5. The time now is 05:25 PM. |