From bcbabf439094bc4dee2b4f12475cfbeabc2ff5ee Mon Sep 17 00:00:00 2001 From: Ben England Date: Mon, 10 Sep 2018 08:48:05 -0400 Subject: [PATCH] raise exception if test start time can't be estimated do not allow log_unix_epoch=1 with single-record histogram log and no log_hist_msec parameter, because then we have no way of estimating when the test started in absolute time. --- tools/hist/fio-histo-log-pctiles.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/hist/fio-histo-log-pctiles.py b/tools/hist/fio-histo-log-pctiles.py index a150e8e3..81f6de6e 100755 --- a/tools/hist/fio-histo-log-pctiles.py +++ b/tools/hist/fio-histo-log-pctiles.py @@ -115,6 +115,8 @@ def parse_hist_file(logfn, buckets_per_interval, log_hist_msec): elif len(intervals) > 1: (second_timestamp, _, _, _) = intervals[1] start_time = first_timestamp - (second_timestamp - first_timestamp) + else: + raise FioHistoLogExc('no way to estimate test start time') (end_timestamp, _, _, _) = intervals[-1] return (intervals, start_time, end_timestamp) -- 2.25.1