lkml.org 
[lkml]   [2013]   [Feb]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: btrfs crash when low on memory.
From
On Wed, Feb 27, 2013 at 7:26 PM, Josef Bacik <jbacik@fusionio.com> wrote:
> On Wed, Feb 27, 2013 at 07:31:11AM -0700, Ahmet Inan wrote:
>> > Yeah we have a lot of
>> >
>> > ptr = kmalloc();
>> > BUG_ON(ptr);
>> >
>> > everywhere. I'll fix this one up but I really need to sit down and go through
>> > all of them and make sure we do the right thing in all these places. Thanks,
>>
>> But what would be the right thing to do when you got no memory?
>> Spinlock until you can kmalloc? Pre-reserve some memory?
>>
>
> Return ENOMEM? We have a way to abort transactions now, if it's in a horrible
> of enough spot we can just abort the transaction and let the user deal with the
> aftermath, it's nicer than panicing. Thanks,

youre right. i am only afraid of silent corruption of data on aborts:
our guys here trigger OOM all the time with their compilers and
numerical codes (go figure).
and until now we had no more aborts / panics because of
"vm.min_free_kbytes = 65536" and thus no corruption.

my point is:
i like a freezing computer more than an corrupting computer, even if
its a server. reboot to the rescue.

Ahmet


\
 
 \ /
  Last update: 2013-02-27 21:41    [W:0.071 / U:0.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site