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

Block cloning tests. #15631

Merged
merged 1 commit into from
Dec 26, 2023
Merged

Block cloning tests. #15631

merged 1 commit into from
Dec 26, 2023

Conversation

pjd
Copy link
Contributor

@pjd pjd commented Dec 4, 2023

Mostly focusing on testing various corner cases.

Motivation and Context

There are a lot of corner cases related to block cloning that have to be handled in the kernel.
Those additional tests try to exercise as many of those corner cases as possible.

Description

The new tests take a long time to execute (~5h), so they can be executed through a dedicated runfile - bclone.run.
In common.run runfile there are all the tests, except for the corner case tests - for those only 100 randomly selected tests will be executed.

How Has This Been Tested?

The tests pass on FreeBSD and Linux.

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)
  • Tests

Checklist:

@robn
Copy link
Member

robn commented Dec 4, 2023

This is great @pjd, thanks. If no one else gets in I'll try to take a good look through over the weekend.

The new tests take a long time to execute (~5h), so they can be executed through a dedicated runfile - bclone.run.

Is there a useful subset that we could put on the common or sanity lists?

Copy link
Contributor

@behlendorf behlendorf left a comment

Choose a reason for hiding this comment

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

@pjd it's great to see these additional comprehensive tests. If you'd like to test them independently in the CI you could additionally create a bclone.run file and then tweak the top level TESTS files like this. That would let us get them running, see how long they take in the CI environment, and maybe let us pick a subset to run regularly.

-#TEST_ZFSTESTS_RUNFILE="linux.run"
+TEST_ZFSTESTS_RUNFILE="bclone.run"

tests/runfiles/common.run Show resolved Hide resolved
@behlendorf behlendorf added the Status: Code Review Needed Ready for review and testing label Dec 5, 2023
Comment on lines 1 to 4
- If dedup enabled, block_cloning uses dedup.
- block_cloning works only with the same encryption key
- check when block cloning doesn't suppose to work
- check block cloning between two different pools
- test with sync=always,default,disabled
- block cloning from a snapshot
Copy link
Contributor

Choose a reason for hiding this comment

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

nice work, maybe have time at the weekend as well.

don't know but is it important to rebase this, because of some new commit in the master? diff there is across encrypted devices new for example

Copy link
Contributor

Choose a reason for hiding this comment

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

Also some tests are added for encrypted datasets.

TEST Outdated Show resolved Hide resolved
@pjd pjd force-pushed the brt-tests branch 6 times, most recently from edb220f to 11b7fee Compare December 18, 2023 23:20
@pjd pjd mentioned this pull request Dec 19, 2023
14 tasks
@pjd
Copy link
Contributor Author

pjd commented Dec 19, 2023

This is great @pjd, thanks. If no one else gets in I'll try to take a good look through over the weekend.

The new tests take a long time to execute (~5h), so they can be executed through a dedicated runfile - bclone.run.

Is there a useful subset that we could put on the common or sanity lists?

Yes, I've added all short tests to common.run plus 100 randomly selected at each run corner case tests.

@pjd pjd force-pushed the brt-tests branch 2 times, most recently from 51cef8e to dc92915 Compare December 20, 2023 05:43
@pjd pjd force-pushed the brt-tests branch 3 times, most recently from 6b34d27 to de8c653 Compare December 22, 2023 00:20
The test mostly focus on testing various corner cases.
The tests take a long time to run, so for the common.run runfile
we randomly select a hundred tests.
To run all the bclone tests, bclone.run runfile should be used.

Signed-off-by: Pawel Jakub Dawidek <[email protected]>
@behlendorf behlendorf added Status: Accepted Ready to integrate (reviewed, tested) and removed Status: Code Review Needed Ready for review and testing labels Dec 26, 2023
@behlendorf behlendorf merged commit 4cf4bc7 into openzfs:master Dec 26, 2023
24 of 25 checks passed
mmatuska pushed a commit to mmatuska/zfs that referenced this pull request Jan 17, 2024
The test mostly focus on testing various corner cases.
The tests take a long time to run, so for the common.run runfile
we randomly select a hundred tests.
To run all the bclone tests, bclone.run runfile should be used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Pawel Jakub Dawidek <[email protected]>
Closes openzfs#15631
mmatuska pushed a commit to mmatuska/zfs that referenced this pull request Jan 18, 2024
The test mostly focus on testing various corner cases.
The tests take a long time to run, so for the common.run runfile
we randomly select a hundred tests.
To run all the bclone tests, bclone.run runfile should be used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Pawel Jakub Dawidek <[email protected]>
Closes openzfs#15631
mmatuska pushed a commit to mmatuska/zfs that referenced this pull request Jan 18, 2024
The test mostly focus on testing various corner cases.
The tests take a long time to run, so for the common.run runfile
we randomly select a hundred tests.
To run all the bclone tests, bclone.run runfile should be used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Pawel Jakub Dawidek <[email protected]>
Closes openzfs#15631
behlendorf pushed a commit that referenced this pull request Jan 19, 2024
The test mostly focus on testing various corner cases.
The tests take a long time to run, so for the common.run runfile
we randomly select a hundred tests.
To run all the bclone tests, bclone.run runfile should be used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Pawel Jakub Dawidek <[email protected]>
Closes #15631
lundman pushed a commit to openzfsonwindows/openzfs that referenced this pull request Mar 13, 2024
The test mostly focus on testing various corner cases.
The tests take a long time to run, so for the common.run runfile
we randomly select a hundred tests.
To run all the bclone tests, bclone.run runfile should be used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Pawel Jakub Dawidek <[email protected]>
Closes openzfs#15631
lundman pushed a commit to openzfsonwindows/openzfs that referenced this pull request Mar 13, 2024
The test mostly focus on testing various corner cases.
The tests take a long time to run, so for the common.run runfile
we randomly select a hundred tests.
To run all the bclone tests, bclone.run runfile should be used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Pawel Jakub Dawidek <[email protected]>
Closes openzfs#15631
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.

4 participants