Bug #38538
Performance improvements for object-map
0%
Description
The "object_map_update" OSD class method has a some low-hanging improvements that can be made to increase the performance of object-map updates:
1) the std::vector BitVector used for the bitset data is zeroed before it's contents are replaced with the bitset data read from the object-map object. This is a huge unnecessary CPU hit for larger object-maps.
2) the entire footer is read into memory even though only 4 bytes might be changed for an updated CRC. For large RBD images, this could be up to 16KiB of data in the worst-case scenario.
A stress-test against librados_test_stub shows improvement from ~100 updates/sec to over 50K updates/sec. The OSD is still limited to approximately 2-3K write operations per second, so longer term refactoring of the object-map design will be required to improve it's performance by orders of magnitude.
Related issues
History
#1 Updated by Jason Dillaman about 5 years ago
- Status changed from In Progress to Fix Under Review
- Pull request ID set to 26721
#2 Updated by Mykola Golub about 5 years ago
- Status changed from Fix Under Review to Pending Backport
#3 Updated by Nathan Cutler about 5 years ago
- Copied to Backport #38673: mimic: Performance improvements for object-map added
#4 Updated by Nathan Cutler about 5 years ago
- Copied to Backport #38674: luminous: Performance improvements for object-map added
#5 Updated by Jason Dillaman over 4 years ago
- Description updated (diff)
#6 Updated by Nathan Cutler about 3 years ago
- Status changed from Pending Backport to Resolved
While running with --resolve-parent, the script "backport-create-issue" noticed that all backports of this issue are in status "Resolved" or "Rejected".