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

Autotrim High Load Average Fix #15781

Merged
merged 1 commit into from
Jan 17, 2024
Merged

Autotrim High Load Average Fix #15781

merged 1 commit into from
Jan 17, 2024

Conversation

jxdking
Copy link
Contributor

@jxdking jxdking commented Jan 16, 2024

Switch from cv_wait() to cv_wait_idle() inside vdev_autotrim_wait_kick(), which should mitigate the high load average while waiting.

Motivation and Context

Attempt to fix the issue #15453

How Has This Been Tested?

Not tested. Need help from the community to test if this fixes the issue.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Library ABI change (libzfs, libzfs_core, libnvpair, libuutil and libzfsbootenv)
  • Documentation (a change to man pages or other documentation)

Checklist:

@amotin
Copy link
Member

amotin commented Jan 16, 2024

Just I suppose it is not a high CPU usage, but high load average. The title is misleading.

@jxdking jxdking changed the title Autotrim High CPU Usage Fix Autotrim High Load Average Fix Jan 16, 2024
@jxdking
Copy link
Contributor Author

jxdking commented Jan 16, 2024

Just I suppose it is not a high CPU usage, but high load average. The title is misleading.

Thank you.
I have updated the pull request. I will amend the commit message later.

@behlendorf behlendorf added the Status: Code Review Needed Ready for review and testing label Jan 16, 2024
Copy link
Contributor

@bwatkinson bwatkinson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me. You just need to fix some of the checkstyle issues with the commit message body length and the line 199 being over 80 characters.

Switch from cv_wait() to cv_wait_idle() in vdev_autotrim_wait_kick(),
which should mitigate the high load average while waiting.

Signed-off-by: jxdking <[email protected]>
@behlendorf behlendorf added Status: Accepted Ready to integrate (reviewed, tested) and removed Status: Code Review Needed Ready for review and testing labels Jan 16, 2024
@mmatuska
Copy link
Contributor

@jxdking It would be great to have this in 2.2.3

@behlendorf behlendorf merged commit 1494e8f into openzfs:master Jan 17, 2024
24 of 26 checks passed
mmatuska pushed a commit to mmatuska/zfs that referenced this pull request Jan 17, 2024
Switch from cv_wait() to cv_wait_idle() in vdev_autotrim_wait_kick(),
which should mitigate the high load average while waiting.

Reviewed-by: Brian Atkinson <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Alexander Motin <[email protected]>
Signed-off-by: jxdking <[email protected]>
Closes openzfs#15781
behlendorf pushed a commit that referenced this pull request Jan 18, 2024
Switch from cv_wait() to cv_wait_idle() in vdev_autotrim_wait_kick(),
which should mitigate the high load average while waiting.

Reviewed-by: Brian Atkinson <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Alexander Motin <[email protected]>
Signed-off-by: jxdking <[email protected]>
Closes #15781
lundman pushed a commit to openzfsonwindows/openzfs that referenced this pull request Mar 13, 2024
Switch from cv_wait() to cv_wait_idle() in vdev_autotrim_wait_kick(),
which should mitigate the high load average while waiting.

Reviewed-by: Brian Atkinson <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Alexander Motin <[email protected]>
Signed-off-by: jxdking <[email protected]>
Closes openzfs#15781
lundman pushed a commit to openzfsonwindows/openzfs that referenced this pull request Mar 13, 2024
Switch from cv_wait() to cv_wait_idle() in vdev_autotrim_wait_kick(),
which should mitigate the high load average while waiting.

Reviewed-by: Brian Atkinson <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Alexander Motin <[email protected]>
Signed-off-by: jxdking <[email protected]>
Closes openzfs#15781
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Accepted Ready to integrate (reviewed, tested)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants