Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Performance creating multiple small files

Tags:

performance

c#

I need a test app that will create a big number of small files on disk as faster as possible.

Will asynch ops help creating files or just writing them? Is there a way to speed up the whole process (writing on a single file is not possible)

like image 414
pablo Avatar asked May 27 '26 12:05

pablo


2 Answers

Wouldn't physical drive IO be the bottleneck here? You'll probably get different results if you write to a 4200rpm drive versus a 10,000rpm drive versus an ultrafast SSD.

like image 188
thedz Avatar answered May 30 '26 04:05

thedz


It's hard for me to say without writing a test app myself, but disc access will be synchronized anyway, so it's not like you will have multiple threads writing to disk at the same time. You could speed up your performance by using threads if there was a fair amount of processing done before writing out each file.

like image 42
Ed S. Avatar answered May 30 '26 02:05

Ed S.



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!