xssnick / TON-Torrent

TON Storage UI
GNU General Public License v2.0
99 stars 6 forks source link

High CPU usage every 20 seconds - several minutes #17

Closed Dymeth closed 11 months ago

Dymeth commented 11 months ago

It is unclear what this behavior is related to, as it occurs at various intervals from 20 seconds to several minutes, and also does not appear to be related to this server giving up data (it is a peer for some active-sharing bags for now). The duration of the problem periods ranges from 4 to 8 seconds.

image

Video demonstration: https://youtu.be/SOcJRiqJ3FE (use timecodes in the description)

Server info: OS: Ubuntu 22.04 jammy Kernel: x86_64 Linux 5.15.0-88-generic Disk: 9,7G / 437G (3%) CPU: AMD Ryzen 5 3600 6-Core @ 12x 3.6GHz RAM: 36019MiB / 64220MiB

If this behavior is not a bug, it would be great to be able to limit CPU consumption (configurable in config or something like that)

Andy4Vendetta commented 11 months ago

I have the same issue on Arch Linux with 6.6.2-zen1-1-zen kernel on my PC

xssnick commented 11 months ago

This is a known issue, high consumption happens due to too aggressive waiting of peer discovery result from DHT, already fixed in dev branch of tonutils-go, and will be fixed in the next version of torrent, approx next week.

xssnick commented 11 months ago

Should be fixed in v1.1.0