How can I limit the cache used by copying so there is still memory available for other cache?

前端 未结 7 1301
春和景丽
春和景丽 2020-12-29 22:51

Basic situation:

I am copying some NTFS disks in openSuSE. Each one is 2TB. When I do this, the system runs slow.

My guesses:

7条回答
  •  情话喂你
    2020-12-29 23:14

    The kernel can not know, that you won't use the cached data from copying agains. This is your information advantage.

    But you could set the swapiness to 0: sudo sysctl vm.swappiness=0. This will cause linux to drop the cache before libraries etc. are written to the swap.

    Works nice for me too, especially very performant in combination with hugh ram (16-32 GB).

提交回复
热议问题