Bug #7531
closedAssign correct flags to prefetched buffers
100%
Description
Hello,
As discussed (same subject) on developer[at]lists.open-zfs.org :
I found that some buffers that could be L2ARC eligible are not flagged such, leading to some performance impact.
As a test I ran the same IO workload 10 times in a raw.
It is a metadata only workload (files listing).
l2arc_noprefetch=0.
Here is the activity of my pool disks during this test :
the first scale is in %, not in ms
We can see that the first files' listing takes about 3 hours, during which the SSD cache is fed.
The other runs take about 35 minutes each, read IOs are made from SSD cache but also from HDD disks, cache is no more fed.
After some debugging, I found that the buffers which are not L2-backed are metadata buffers, as the ones which are in the cache, but are not ARC_FLAG_L2CACHE flagged.
I then quickly modified ZFS code to add ARC_FLAG_L2CACHE to each header, and here is the result :
the first scale is in %, not in ms
All IOs now come from the cache, leading to a nice performance improvement. Perfect.
A PR will be proposed soon to correct this issue.
Thank you,
Ben
Updated by Ben RUBSON over 6 years ago
Updated by Ben RUBSON almost 6 years ago
Initial mailing list discussion :
https://openzfs.topicbox.com/groups/developer/T5c86de0027fd607d-Mcd7507e12c946b6f594a2099
Updated by Prakash Surya over 5 years ago
- Subject changed from Buffers not L2 flagged, performance impact to Assign correct flags to prefetched buffers
Updated by Electric Monk over 5 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
git commit 272952165423c254ad7708f1b3fe2ff0a6ce408b
commit 272952165423c254ad7708f1b3fe2ff0a6ce408b Author: benrubson <ben.rubson@gmail.com> Date: 2017-11-09T15:09:45.000Z 7531 Assign correct flags to prefetched buffers Reviewed by: Matthew Ahrens <mahrens@delphix.com> Reviewed by: Prakash Surya <prakash.surya@delphix.com> Approved by: Dan McDonald <danmcd@joyent.com>