fio: fix ignore_error regression
PATCH 1/1 fio: fix ignore_error regression
Commit e9d512d8e7d2 introduced a regression affecting handling for the ignore_error parameter. The common code for io_u event handling pulled from do_io() and do_verify() into io_queue_event() does not check for and process errors that are to be ignored in the main I/O path as I/Os are completed. Prior to that commit, do_io() called break_on_this_error() to handle that case.
The change causes fio to return a non-zero exit status after encountering an error it should ignore while performing I/O, even though the job does run to completion. This regression causes failures for some fstests that use fio, including ext4/302, ext4/303, and generic/300.
This patch restores the original error handling behavior.
--- backend.c | 8 ++++++++ 1 file changed, 8 insertions(+)
backend.c +8 -0
@@ -520,6 +520,14 @@ sync_done:if (*ret <0 )break ; } + +/* +* when doing I/O (not when verifying), +* check for any errors that are to be ignored +*/ +if (!from_verify) +break ; +return 0 ;case FIO_Q_QUEUED :/*
Signature · 1 line
2.1.4
Quoted 7 lines · Eric Whitney
Commit
e9d512d8e7d2introduced a regression affecting handling for theignore_errorparameter. The common code forio_uevent handling pulled fromdo_io()anddo_verify()intoio_queue_event()does not check for and process errors that are to be ignored in the main I/O path as I/Os are completed. Prior to that commit,do_io()calledbreak_on_this_error()to handle that case.
Quoted 7 lines
The change causes fio to return a non-zero exit status after encountering an error it should ignore while performing I/O, even though the job does run to completion. This regression causes failures for some fstests that use fio, including ext4/302, ext4/303, and generic/300.
This patch restores the original error handling behavior.
Thanks Eric, good catch! Applied.
Signature · 1 line
Jens Axboe