summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 3f2ebfa)
raw | patch | inline | side by side (parent: 3f2ebfa)
author | Kevin Bowling <kbowling@llnw.com> | |
Mon, 4 Apr 2016 09:13:08 +0000 (02:13 -0700) | ||
committer | Kevin Bowling <kbowling@llnw.com> | |
Mon, 4 Apr 2016 09:13:08 +0000 (02:13 -0700) |
src/disk.c | patch | blob | history |
diff --git a/src/disk.c b/src/disk.c
index 05a863fb01666cd1764c880cc462c30e337738d6..1dbdd9de543cca3fe65315a561b4d494e2e62dcc 100644 (file)
--- a/src/disk.c
+++ b/src/disk.c
struct gident *geom_id;
const char *disk_name;
- long double read_time, write_time;
+ long double read_time, write_time, busy_time, total_duration;
for (retry = 0, dirty = 1; retry < 5 && dirty == 1; retry++) {
if (snap != NULL)
disk_submit (disk_name, "disk_time",
(derive_t)(read_time*1000), (derive_t)(write_time*1000));
}
+ if (devstat_compute_statistics(snap_iter, NULL, 1.0,
+ DSM_TOTAL_BUSY_TIME, &busy_time,
+ DSM_TOTAL_DURATION, &total_duration,
+ DSM_NONE) != 0) {
+ WARNING("%s", devstat_errbuf);
+ }
+ else
+ {
+ submit_io_time(disk_name, busy_time, total_duration);
+ }
}
geom_stats_snapshot_free(snap);