-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ZFS does not honor "echo 3 > drop_cache" #12810
Comments
This is likely a consequence of the ARC changes made in PR #10600 (commit 3442c2a) which limited how much of the ARC could be reclaimed in a single pass. In part, the motivation here was the prevent the case where too much was reclaimed from the ARC when memory was low. This could lead to a poor hit rate and large latency spikes while the reclaim was in progress. Interestingly, I wasn't able to easily reproduce this problem with OpenZFS 2.1 with the RHEL 4.18.0-305.25.1 kernel. However, I see you're using the 3.10.0-1160.45.1 which may behave a bit differently (there were significant kernel changes in this area). If you're game, I can suggest a workaround which may work for you and I'd be interested to know the results.
|
Related PR #12228. |
Your suggested solution (
Thank you for the quick feedback and for pointing me to the relative commit. |
This issue has been automatically marked as "stale" because it has not had any activity for a while. It will be closed in 90 days if no further activity occurs. Thank you for your contributions. |
System information
Describe the problem you're observing
ZFS does not drop caches when kernel is asked to do that via
echo 3 > /proc/sys/vm/drop_caches
Practical example:
Please see how little differs the first, pre-drop
arc_summary
from the second, post-drop one. It almost seems as nowecho 3 > /proc/sys/vm/drop_caches
only runs a single iteration of the ARC shrinker.The very same test works flawlessly on ZFS 0.7 and 0.8 releases. Not being able to release memory in emergency situations when using ZFS 2.0.x can be a significant issue.
Describe how to reproduce the problem
Bring some data in ARC and then try to release them via
echo 3 > /proc/sys/vm/drop_caches
Include any warning/errors/backtraces from the system logs
The text was updated successfully, but these errors were encountered: