Closed
Description
System information
Type | Version/Name |
---|---|
Distribution Name | Proxmox VE |
Distribution Version | pvetest |
Kernel Version | Linux 6.8.12-2-pve |
Architecture | x86_64 |
OpenZFS Version | zfs-2.2.6-pve1 , zfs-kmod-2.2.6-pve1 |
Describe the problem you're observing
MRU and MFU don't change to their target sizes, especially when ARC is near its target size. It seems that arc_evict()
scales the amount to get evicted proportionally to the difference between ARC's target size and current size. So when ARC is close to its target size, only a small amount of memory gets evicted. Maybe that's why MRU and MFU cannot reach their target sizes. Perhaps all the MINs in arc_evict()
should be MAXs instead?
Describe how to reproduce the problem
# Limit arc max to 2GB during test
echo $((2*1024*1024*1024)) >> /sys/module/zfs/parameters/zfs_arc_max
# Before
c size mfu-size mfu-data-target mru-size mru-data-target
983M 276M 79M 80M 134M 80M
# Write 2.1 GB file to fill ARC. Also fill MRU and change its target size
dd if=/dev/urandom of=./2.1.img bs=1M count=2150
# Check MRU, MFU sizes **every 10 minutes**.
# Their sizes don't change much and are very different from targets.
c size mfu-size mfu-data-target mru-size mru-data-target
2.0G 2.0G 69M 741M 1.9G 741M
2.0G 2.0G 70M 742M 1.9G 742M
2.0G 2.0G 70M 743M 1.9G 743M
2.0G 2.0G 70M 743M 1.9G 743M
2.0G 2.0G 70M 743M 1.9G 743M
2.0G 2.0G 70M 743M 1.9G 743M