Hi guys, I’m sorry I keep asking questions.
I was going through the config.yam and came across the # in-memory buffer for uploads option.

I did search the forums but didn’t find any information regarding this option.
Is it worth enabling something like 512MiB or even 1GiB as write cache? Will it improve node performance? I understand it does increase the risk of data corruption in case of an ungraceful shutdown but I’m behind a UPS so hopefully that is somewhat unlikely.

Any thoughts?


1 Like

There is a some duscussion and testing of this option already in this topic: Machine freezing for short periods

The write-buffer-size sets the in-memory buffer for incoming pieces. You would need to have that much RAM available per upload request. So, you could end up getting out-of-memory errors when you set it too high.

But, there’s really no benefit it setting it over 4MiB. At most it would need to store the whole piece, which at the moment is ~4MiB. Setting it to that number is only useful for drives that don’t like small writes (such as SMR drives). This of course will mean that it needs to write all that data at once to disk when the upload finishes, making the final sync to disk slower.

There shouldn’t be any increased risk in data corruption.