Skip to content

Instantly share code, notes, and snippets.

@hackery
Created February 4, 2021 00:10
Show Gist options
  • Save hackery/b85f99e19b4cf24dd489bb988adb6705 to your computer and use it in GitHub Desktop.
Save hackery/b85f99e19b4cf24dd489bb988adb6705 to your computer and use it in GitHub Desktop.
jmb@zen:~/xfer$ time sudo strace -tT -o /tmp/strace.hdparm hdparm -t /dev/mapper/sys0-root /dev/mapper/sys0-root: HDIO_DRIVE_CMD(identify) failed: Inappropriate ioctl for device Timing buffered disk reads: 3394 MB in 3.00 seconds = 1131.26 MB/sec real 8m26.623s user 0m0.100s sys 0m1.850s
/dev/mapper/sys0-root:
HDIO_DRIVE_CMD(identify) failed: Inappropriate ioctl for device
Timing buffered disk reads: 3394 MB in 3.00 seconds = 1131.26 MB/sec
real 8m26.623s
user 0m0.100s
sys 0m1.850s
23:50:11 execve("/sbin/hdparm", ["hdparm", "-t", "/dev/mapper/sys0-root"], 0x7ffd0b643c58 /* 17 vars */) = 0 <0.000213>
...
23:50:11 openat(AT_FDCWD, "/dev/mapper/sys0-root", O_RDONLY|O_NONBLOCK) = 3 <0.000021>
23:50:11 write(1, "/dev/mapper/sys0-root:\n", 23) = 23 <0.000011>
... 200ish lines of status probe / setup
23:50:11 sync() = 0 <99.261508>
23:51:51 clock_nanosleep(CLOCK_REALTIME, 0, {tv_sec=3, tv_nsec=0}, 0x7fff9eea73b0) = 0 <3.000138>
23:51:54 write(1, " Timing buffered disk reads: ", 29) = 29 <0.000023>
...
... 3400 lines of read(3,...) and getitimer()
23:51:57 getitimer(ITIMER_REAL, {it_interval={tv_sec=1000, tv_usec=0}, it_value={tv_sec=996, tv_usec=999759}}) = 0 <0.000008>
23:51:57 write(1, "3394 MB in 3.00 seconds = 1131."..., 42) = 42 <0.000016>
23:51:57 munlockall() = 0 <0.006417>
23:51:57 munmap(0x7f1cd62ca000, 2097152) = 0 <0.000134>
23:51:57 sync() = 0 <147.874626>
23:54:25 fsync(3) = 0 <0.002552>
23:54:25 fdatasync(3) = 0 <0.000117>
23:54:25 sync() = 0 <167.969618>
23:57:13 ioctl(3, BLKFLSBUF) = 0 <0.219426>
23:57:13 ioctl(3, HDIO_DRIVE_CMD, 0) = -1 ENOTTY (Inappropriate ioctl for device) <0.000014>
23:57:13 sync() = 0 <85.257365>
23:58:38 close(3) = 0 <0.000017>
23:58:38 exit_group(0) = ?
23:58:38 +++ exited with 0 +++
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment