lkml.org 
[lkml]   [2011]   [Nov]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: ext4 bug ? "Intel 320 SSD write perfo rmance – contd."
From
Date

On Nov 1, 2011, at 9:34 AM, Stephen Clark wrote:

>>
>> You can enable the trim behaviour by default by adding to your
>> /etc/mke2fs.conf file:
>>
>> [defaults]
>> discard = true
>>
>> But then it's on your head if anything bad happens. :-/
>>
>> - Ted
>>
>>
> <snip>
>
> What about using discard in fstab like:
> LABEL=/ / ext4 defaults,discard,noatime,nodiratime 1 1

That does something different; this does continuous discards as you delete files. This is probably the best thing to do if you are using thin-provisioning. However, with SATA devices, a discard requires a queue flush, which can be a performance disaster. (Also some cheaper SSD's also have real performance difficulties if there are frequent trims.) There have also been reports that high frequency discards can trigger bugs that cause crappier SSD's to turn themselves into bricks. The performance problems and the possibility of bricking crappier SSD's is why this isn't turned on by default.

Because of this, another method is to do FITRIM's periodically using cron. This has less of a performance impact, so it's probably the better approach in many cases.

Basically, with SSD's and thin-provisioning systems, we are very much at the mercy at the competence of firmware authors. As we know, sometimes firmware authors can be quite competent, or very, extremely incompetent. So there will be a wide range of outcomes, which is one of the reasons why the best answer is to test to see what works best for you, preferably before you put use your systems in production.

-- Ted



\
 
 \ /
  Last update: 2011-11-01 14:49    [W:0.054 / U:14.080 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site