swap/journaling on an SSD?

Started by DarklingAlice, December 18, 2010, 08:43:02 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

DarklingAlice

So this is kind of a fringe issue, but what the hell.

I have been hearing a lot of arguments for and against setting aside a swap partition or using a journaling file system when installing an OS on a solid state drive. The detractors seem to say that SSDs can only handle a limited number of total writes before they 'wear out'. Those pro-swap/journaling say that A) the advantages outweigh the risks, and B) that while it is true that there are a limited number of total writes, you won't reach anywhere near said limit in a reasonable time-frame of computer use (e.g. it will take 5-10 years of constant computing to get there).

I know nothing about computer hardware, and am thinking I might just err on the side of caution, but I wanted to check and see if anyone here had details or opinions.
For every complex problem there is a solution that is simple, elegant, and wrong.


Vekseid

Well if you're referring to a physical journal, you're cutting your disk bandwidth in half anyway. For a logical journal (which is probably what you would be using unless you specify otherwise), the amount of writes done to the journal is a fraction of overall writes. A drive that supports wear-leveling and an OS that supports TRIM (Windows 7, FreeBSD 9, Linux as of 2.6.33) can help with performance degradation, but this is an issue of the OS overwriting the same area of disk (the journal), over and over again, not with it 'dying' on you.

Whether or not you use it for swap swap really depends on what you're using your computer for, and why you need more than a token swap file (for system recovery in Windows, or for reclaiming a few extra megs on Linux). MLC SSDs are a poor substitute for RAM, of course, but SLC SSDs have been chained together and used to essentially provide terabytes of slightly-slower speed RAM on a single machine.

The way most modern machines use swap, it won't be an issue. I'm still a little leery of MLC SSDs, so I opted not to use them for E's server, but Elliquiy has a sustained write rate of about 2 megabytes per second at the moment (~150gb of data gets written to Elliquiy's disks each day, not counting the slave server). The lower end of the reported lifespan (a thousand write cycles) would mean Elliquiy would destroy a low-end 64GB SSD in about a year.

A low end SLC SSD (lasting 50k write cycles), on the other hand, would last the better part of a century. But I couldn't afford those, unfortunately. Plus TRIM wasn't supported in Squeeze.

So the obvious question is, "Are you seriously going to be writing over a hundred gigabytes of data to disk per day?"

If the answer is 'no', I probably wouldn't worry about it : )

If the answer is 'yes', I would advise looking into SLC SSDs instead. And if those are cheap to you please buy me a few : /

DarklingAlice

You are a lifesaver! Or at least a [several hours of confusion and consternation]saver. Thank you so much!
For every complex problem there is a solution that is simple, elegant, and wrong.