Open thememika opened 4 hours ago
Sorry that was a mistype in the name. It's not about encryption
In fs/bcachefs/compress.c:407
:
workspace = mempool_alloc(&c->compress_workspace[compression_type], GFP_NOFS);
You never check for allocation failure afterwards. And attempt_compress
also doesn't when you pass workspace
to it. And so all the way until LZ4_compress_HC()
or LZ4_compress_destSize()
who also do not.
Can it be the source of the problem?
That would explain why this problem is more likely to be reproduced when host is under memory pressure. Ohh I hope everything was so simple. I'll try to add a check and rebuild. But I'm still unsure how to properly return error there after alloc
Hello, this issue already existed in bcachefs and my original post was https://github.com/koverstreet/bcachefs/issues/753. It seemed to be absolutely fixed after I backported many commits which followed the issue. My current commit I use is 0f25eb4b60771f08fbcca878a8f7f88086d0c885 ("
Rework logged op handling
", branchbcachefs-for-upstream
, 2024-10-04 20:25:32 -0400). Recently I have decided to compress some files on my filesystem and I have chosenlz4:6
. I usedbackground_compression
attr for each of these files. It was done in the evening and I expected it to compress files overnight. But at 5:00 morning this happened:This is my configuration.
Thanks.