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/031: remove the fio verify.state file #145

Conversation

yizhanglinux
Copy link
Contributor

Remove the fio verify.state file local-block-031-0-verify.state after fio finished

@kawasaki
Copy link
Collaborator

kawasaki commented Oct 4, 2024

@yizhanglinux Thank you for catching this! The file should not be left.

As for the solution, how about to add "--verify_state_save=0" option to the fio command? This approach does not create the file, then a bit cleaner than "create the file and remove it".

diff --git a/tests/block/031 b/tests/block/031
index 5ad6d88..99615ec 100755
--- a/tests/block/031
+++ b/tests/block/031
@@ -45,7 +45,7 @@ test() {
                --ioengine=libaio --runtime="${TIMEOUT}" --thread \
                --name=block-031 --filename=/dev/nullb1 \
                --output="${RESULTS_DIR}/block/fio-output-031.txt" \
-               >>"$FULL"
+               --verify_state_save=0 >>"$FULL"
        fio_status=$?
        rmdir /sys/kernel/config/nullb/nullb1
        _exit_null_blk

Add fio option --verify_state_save to not save the verify.state file

Suggested-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Signed-off-by: Yi Zhang <yi.zhang@redhat.com>
@yizhanglinux yizhanglinux force-pushed the rm-block-031-fio-verify-state-file branch 3 times, most recently from b16f7e4 to 02302d0 Compare October 8, 2024 07:44
Add fio option --verify_state_save=0 to not save the verify.state file

Signed-off-by: Yi Zhang <yi.zhang@redhat.com>
Remove the fio verify.state files after fio finished

Signed-off-by: Yi Zhang <yi.zhang@redhat.com>
@yizhanglinux
Copy link
Contributor Author

@yizhanglinux Thank you for catching this! The file should not be left.

As for the solution, how about to add "--verify_state_save=0" option to the fio command? This approach does not create the file, then a bit cleaner than "create the file and remove it".

diff --git a/tests/block/031 b/tests/block/031
index 5ad6d88..99615ec 100755
--- a/tests/block/031
+++ b/tests/block/031
@@ -45,7 +45,7 @@ test() {
                --ioengine=libaio --runtime="${TIMEOUT}" --thread \
                --name=block-031 --filename=/dev/nullb1 \
                --output="${RESULTS_DIR}/block/fio-output-031.txt" \
-               >>"$FULL"
+               --verify_state_save=0 >>"$FULL"
        fio_status=$?
        rmdir /sys/kernel/config/nullb/nullb1
        _exit_null_blk

Yeah, that's a better way, just pushed another two commit for the verify.state file cleanup.

@yizhanglinux
Copy link
Contributor Author

++ @bvanassche

@kawasaki
Copy link
Collaborator

kawasaki commented Oct 9, 2024

@yizhanglinux thanks, all three changes look good to me. I ran whole blktests, and did not see regression. One small nit change is the commit message of the 3rd commit. To fix it, I applied the three commits manually. Now they are in the master branch. Thank you!

@kawasaki kawasaki closed this Oct 9, 2024
@yizhanglinux yizhanglinux deleted the rm-block-031-fio-verify-state-file branch October 9, 2024 13:36
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.

2 participants