Enhance the reaped status display
authorJens Axboe <axboe@kernel.dk>
Fri, 30 Mar 2012 19:21:20 +0000 (21:21 +0200)
committerJens Axboe <axboe@kernel.dk>
Fri, 30 Mar 2012 19:21:20 +0000 (21:21 +0200)
Instead of just printing a '_' for a job that has exited,
allow the user to tell if the job exited with an error or
not. A normally reaped job that ran to completion without
errors will have the '_' displayed. If the job exited with
an error, then an 'X' will be displayed instead.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
HOWTO
eta.c

diff --git a/HOWTO b/HOWTO
index 5622349fe7707aee6d1757fedf6b17dbf9a56e94..62c70cb4d3d4c25268c0b8291da79bac5f5397d7 100644 (file)
--- a/HOWTO
+++ b/HOWTO
@@ -1339,13 +1339,16 @@ I               Thread initialized, waiting.
        F       Running, currently waiting for fsync()
        V       Running, doing verification of written data.
 E              Thread exited, not reaped by main thread yet.
-_              Thread reaped.
+_              Thread reaped, or
+X              Thread reaped, exited with an error.
 
 The other values are fairly self explanatory - number of threads
 currently running and doing io, rate of io since last check (read speed
 listed first, then write speed), and the estimated completion percentage
 and time for the running group. It's impossible to estimate runtime of
-the following groups (if any).
+the following groups (if any). Note that the string is displayed in order,
+so it's possible to tell which of the jobs are currently doing what. The
+first character is the first job defined in the job file, and so forth.
 
 When fio is done (or interrupted by ctrl-c), it will show the data for
 each thread, group of threads, and disks in that order. For each data
diff --git a/eta.c b/eta.c
index 6118d1af21b5afccee8c9f106bc4cbd93b557c61..4ad67629580cdb2b567166bd111282c4fb094bfa 100644 (file)
--- a/eta.c
+++ b/eta.c
@@ -18,7 +18,10 @@ static void check_str_update(struct thread_data *td)
 
        switch (td->runstate) {
        case TD_REAPED:
-               c = '_';
+               if (td->error)
+                       c = 'X';
+               else
+                       c = '_';
                break;
        case TD_EXITED:
                c = 'E';