-
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
memory leak in trim branch #6185
Comments
Referencing #5925. |
I did some 'divide and conquer' testing and I believe this change: commit 19a677f
introduced the memory leak, since with the previous commit e83b488 the behaviour is not seen. |
This diff takes care of the kmem leak:
|
@ms-fastlta thanks for running this down, I accidentally dropped that kmem_free() when removing the conditional (which was intentional). I'll fold this fix in to the TRIM PR. |
@behlendorf |
Closing. This fix was merged in to open TRIM PR. |
System information
Describe the problem you're observing
This code (branch 'ntrim2', commit f727c0e) contains a memory leak that is causing the OOM killer to kill anything sizeable in userland on the following tests:
The tool prints out a line of progress every 100 files. Before this pool fills up completely, oom killer starts killing user-land processes left, right and center (around 30 of them within a few minutes!).
The same test shows no such behaviour with up-to-date zfs-on-linux and otherwise comparable settings.
The machine I'm testing this on has 16GB of RAM, this is the relevant excerpt of /proc/slabinfo, I believe, after the oom killer has effectively terminated my test:
during the test, I can see <active_objs> (col 2) grow by ~200k - 300k every minute.
Is there any information I can supply to help debug this?
Addendum: exporting and re-importing the pool doesn't free up the memory (according to slabinfo).
This may be another instance of #5626
The text was updated successfully, but these errors were encountered: