- 5 Kwiecień 2008
- 10 792
- 2 748
- 405
- Odznaki
- 205
- QNAP
- TS-x77
- Ethernet
- 1 GbE
Symptoms
Cause
rtorrent maps the parts of torrent files it reads and writes into memory: its piece cache. A limit caps it. By default, the limit is a quarter of the NAS's RAM, at least 512 and at most 2048 MiB. These mapped pages are disk cache: the system frees them when another program needs the memory, and rtorrent then reads them from disk again.
rtorrent also uses memory for its peers, trackers and session. Each connection uses memory, so more peers and slots use more memory.
Resolution
Notice & Advise
Ref. links:
Rtorrent 16 guide: Control Center
- The NAS shows high memory use while Rtorrent 16 runs.
- The memory figure of rtorrent grows while torrents download or seed.
Cause
rtorrent maps the parts of torrent files it reads and writes into memory: its piece cache. A limit caps it. By default, the limit is a quarter of the NAS's RAM, at least 512 and at most 2048 MiB. These mapped pages are disk cache: the system frees them when another program needs the memory, and rtorrent then reads them from disk again.
rtorrent also uses memory for its peers, trackers and session. Each connection uses memory, so more peers and slots use more memory.
Resolution
- See what uses the memory. On the Dashboard, the Memory chart of the Processor and memory card shows what each program holds itself: rtorrent, Services and add-ons and Jobs. Mapped files in the key is the part rtorrent has mapped. The grey hatched background shows the whole NAS, without the disk cache.
- Read the piece cache. At the bottom of the Processor and memory card, Piece cache shows the memory in use and the limit.
- Lower the limit. Open Settings → Bandwidth & limits. In the Memory and files row, lower piece cache (MiB). 512 is the lowest value. Press Review & save and confirm the changes in the window that opens. rtorrent applies the new limit without a restart.
- Hold fewer peers. Lower max in the Public profile: peers per torrent and Private profile: peers per torrent rows of Settings → Connection profiles (press Custom to see them).
Notice & Advise
- The memory figure of rtorrent on the Services card includes the mapped files, so it reads higher than the chart.
- On QuTS hero, the key also shows ZFS cache: memory the system keeps for reading files and gives back when programs need it. It does not count as memory in use in the NAS figure.
- A link profile and the proposals on the Performance page can change the piece cache. Both show the old and new value before anything changes.
- A small piece cache can slow down downloads on a fast line.
Ref. links:
Rtorrent 16 guide: Control Center