Implement packing small files into shared inodes

This commit is contained in:
Vitaliy Filippov
2024-03-16 13:24:36 +03:00
parent 181795d748
commit e5bb986164
5 changed files with 930 additions and 284 deletions
+2 -1
View File
@@ -228,7 +228,8 @@ resume_6:
return;
}
// (6) If regular file and inode is deleted: delete data
if ((!st->type || st->type == NF3REG) && st->ientry["nlink"].uint64_value() <= 1)
if ((!st->type || st->type == NF3REG) && st->ientry["nlink"].uint64_value() <= 1 &&
!st->ientry["shared_inode"].uint64_value())
{
// Remove data
st->self->parent->cmd->loop_and_wait(st->self->parent->cmd->start_rm_data(json11::Json::object {