Skip to content
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

SSV-22900: Return the usable spa dspace in the performance metrics ioctl #89

Merged
merged 2 commits into from
Oct 12, 2023

Conversation

datacore-rm
Copy link

@datacore-rm datacore-rm commented Oct 11, 2023

Jira: SSV-22900: CO available space in Disk pool is showing wrong value.

Issue: In the case of raidz1, the DMC was showing the total size of all the raidz1 disks and special mirror vdev and not the actual usable capacity.

Fix: Get the dspace(deflated space) from the spa normal metaslab class and subtract the slop reservation space to get the actual usable pool size.
The commit 7d275c6 (Tinker with slop space accounting with dedup) is a prerequisite commit that was down streamed. Without this commit, more slop space was reserved when deduplication data was present and it was showing lesser available space.

Tests by Dev: -

  1. Tested on both RAID0 and RAID5 to validate that correct zpool sizes and alloc and available details are reported in DMC.
  2. QA also testing in parallel, and results will be updated in https://dcsw.atlassian.net/browse/SSV-22930
  3. ZFS test suite does not exercise the perf metric ioctl. Ran the unit test against ZFS build 15.0.1700.80 and all the tests passed.
    http://10.200.2.48:8080/job/OpenZFS-Test-Suite/115/console

Tests to be done by QA: _

  1. Run DCAF test suite.
  2. Manual testing.

rincebrain and others added 2 commits October 9, 2023 18:51
* Tinker with slop space accounting with dedup

Do not include the deduplicated space usage in the slop space
reservation, it leads to surprising outcomes.

* Update spa_dedup_dspace sometimes

Sometimes, we get into spa_get_slop_space() with
spa_dedup_dspace=~0ULL, AKA "unset", while spa_dspace is correctly set.

So call the code to update it before we use it if we hit that case.

Reviewed-by: Matthew Ahrens <[email protected]>
Reviewed-by: Mark Maybee <[email protected]>
Signed-off-by: Rich Ercolani <[email protected]>
Closes openzfs#12271
@datacore-rm datacore-rm merged commit 282b0b5 into rel-10psp17 Oct 12, 2023
0 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants