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

zpool_trim tests: throttle trim process #11296

Merged
merged 1 commit into from
Dec 7, 2020
Merged

Conversation

gmelikov
Copy link
Member

@gmelikov gmelikov commented Dec 6, 2020

Otherwise trim may finish before progress checks.

It is a prerequisite for running tests in Github VMs.

Signed-off-by: George Melikov [email protected]

Motivation and Context

Fix false negative in tests.

Description

Race condition reproduces easily in github actions' VMs, example: https://github.com/gmelikov/zfs/runs/1504242726?check_suite_focus=true

Fixed run: https://github.com/gmelikov/zfs/runs/1507040525?check_suite_focus=true

Manual commands run gives me same results - trim finishes instantly if pool was empty.

I've done the easiest method - just rewrite some blocks a count of times after race can't be reproduced.

How Has This Been Tested?

Runs in CI, please see links in description.

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:

Otherwise trim may finish before progress checks.

Signed-off-by: George Melikov <[email protected]>
@gmelikov gmelikov requested a review from behlendorf December 6, 2020 19:21
@behlendorf behlendorf added the Status: Code Review Needed Ready for review and testing label Dec 7, 2020
@gmelikov gmelikov mentioned this pull request Dec 7, 2020
8 tasks
@behlendorf behlendorf added Status: Accepted Ready to integrate (reviewed, tested) and removed Status: Code Review Needed Ready for review and testing labels Dec 7, 2020
@behlendorf behlendorf merged commit 8e8fdce into openzfs:master Dec 7, 2020
@gmelikov gmelikov deleted the trim branch December 7, 2020 18:10
ghost pushed a commit to zfsonfreebsd/ZoF that referenced this pull request Dec 23, 2020
Otherwise trim may finish before progress checks.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: George Melikov <[email protected]>
Closes openzfs#11296
behlendorf pushed a commit that referenced this pull request Dec 23, 2020
Otherwise trim may finish before progress checks.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: George Melikov <[email protected]>
Closes #11296
jsai20 pushed a commit to jsai20/zfs that referenced this pull request Mar 30, 2021
Otherwise trim may finish before progress checks.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: George Melikov <[email protected]>
Closes openzfs#11296
sempervictus pushed a commit to sempervictus/zfs that referenced this pull request May 31, 2021
Otherwise trim may finish before progress checks.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: George Melikov <[email protected]>
Closes openzfs#11296
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.

2 participants