BiglySoftware / BiglyBT

Feature-filled Bittorrent client based on the Azureus open source project
https://www.biglybt.com
GNU General Public License v2.0
1.53k stars 152 forks source link

cache not being respected? #2332

Closed as-muncher closed 2 years ago

as-muncher commented 2 years ago

Java 1.8.0_202 (64 bit) Oracle Corporation c:\program files\biglybt\jre

SWT v4942r22, win32, zoom=100, dpi=120 Windows 10 v10.0, amd64 (64 bit) B2.8.0.0/4 az3

I have my cache set to 800 MB for reads and 800 MB for writes before slowing down transfer speeds. I feel like it's not being respected, because I see the download speed drying up, and then coming back up. Is there a way to monitor the cache?

parg commented 2 years ago

Those settings aren't to do with the cache directly, they are to do with how much data (or requests for data) are allowed to be queued.

If you are downloading at 1MB/sec and your disk can only write at 800KB/sec then obviously 200KB/sec of data has to be queued for writing every second. This can't go on forever as you will run out of memory.

If peers are requesting data from you a 1MB/sec and your disk can only read at 800KB/sec then every second 200KB of buffer space will be being allocated and handed over to the IO subsystem for a read operation that isn't returned. This can't go on forever as you will run out of memory.

The Cache view under Stastistics has a data queued for read/write graph.

as-muncher commented 2 years ago

@parg Thanks for responding. It just seems odd that my disk could not write fast enough to keep up with the download speed, which is quite low, not more that 2 MB/s.