[SERVER-7525] Storage Metrics on Fragmentation Created: 01/Nov/12  Updated: 03/Jan/18  Resolved: 22/Aug/16

Status: Closed
Project: Core Server
Component/s: Storage
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Major - P3
Reporter: David Hows Assignee: Keith Bostic (Inactive)
Resolution: Won't Fix Votes: 9
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Related
Backwards Compatibility: Fully Compatible
Participants:
Case:

 Description   

Can we implement metrics which calculate and maintain the current level of fragmentation of the database? Or which keep a total of free space within the currently allocated extents which could be used to calculate the current fragmentation?



 Comments   
Comment by Keith Bostic (Inactive) [ 22/Aug/16 ]

From a discussion with milkie:

  • This ticket originated with the mmap storage engine where fragmentation level had a large effect on performance; as long as there's disk space available, fragmentation generally won't affect WiredTiger performance.
  • WiredTiger does have per-file fragmentation statistics.
  • WiredTiger files require roughly the base size of the data that's not changing frequently, plus 2x the data changing between each checkpoint (there are normally two checkpoints in each file). If there is a lot of base data that's not changing rapidly, the file will tend to be closer to the table's data-set in size; if there's little base data and a lot of data is changing frequently, then the file will tend to be closer to 2x the data-set in size.
  • If a user was seeing excessive file fragmentation, they might tune WiredTiger by increasing checkpoint frequency, or switching from the default best-fit allocation policy to a first-fit block allocation policy, or changing the file's block size, but MongoDB doesn't export those knobs, so currently there's nothing the user can do to adjust fragmentation.

Closing as won't-fix.

Comment by Aaron Clements [ 14/Jul/16 ]

+1 on this. We're running WT and would like to see metrics in Cloud Manager.

Comment by Ian Whalen (Inactive) [ 28/Mar/16 ]

We have no plans to make such changes for the mmapv1 storage engine - putting on the backlog for the WT team to determine how they want to prioritize and proceed.

Generated at Thu Feb 08 03:14:47 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.