Post
Topic
Board Bitcoin Technical Support
Re: Advice Requested on Full Node Build for Advanced Analytics
by
NotATether
on 31/10/2024, 06:49:47 UTC
Shouldn't disk writes be handled by file system cache? To compare, even on an old HDD, writing 10 million small files (yes I do crazy things like that) is almost as fast as sustained writes. Reading them is very slow, because then the disk head needs to search for each file. Writing is fast, straight from file system cache onto the disk.
I'm not sure how this would work with a database, but if writing 3500 transactions takes 4 seconds, that seems slow to me.

Completely depends on the filesystem.

Most of them like ext3, ext4 and such use journalling, so when you batch all that data to write into the disk, it actually goes inside the journal first.

Usually the default settings of the journal is to write deltas of the changed bytes on to the disk. This is more reliable than just doing a write-back to the disk, but it's slightly slower.

You can actually change the filesystem settings to more aggressively utilize the disk cache, but it will only take effect on the next reboot.