I have an application that receives several hundred lines per second, about fifty bytes long, over the network. I want to cache them on an SSD for further processing. Is it safe for SSD if I execute several hundred files with 50 byte file upload per second? I suspect that the OS may combine these entries, but I do not know. I vaguely understand that SSDs are made of cells that need to be updated on an "all or nothing" basis, and that each cell can only withstand as many records (hundreds or thousands, I think, for commodity disks). Is my application with many small entries putting my SSD on the path to destruction? Can I be safer if I cached memory and wrote to disk in chunks every minute / hour? Obviously, this is more complicated (web service for the memory cache for the last minute / hour,drive for older data), but I also prefer not to destroy too much hardware.
I did something not too different from this for months-not-years without adverse effects, but it was many years ago, and I did not conduct any serious tests. I know from experience that I can destroy a hard drive for several months quite reliably with this method, if it is implemented naively.
source
share