1ext4slower(8)               System Manager's Manual              ext4slower(8)
2
3
4

NAME

6       ext4slower - Trace slow ext4 file operations, with per-event details.
7

SYNOPSIS

9       ext4slower [-h] [-j] [-p PID] [min_ms]
10

DESCRIPTION

12       This tool traces common ext4 file operations: reads, writes, opens, and
13       syncs. It measures the time  spent  in  these  operations,  and  prints
14       details for each that exceeded a threshold.
15
16       WARNING: See the OVERHEAD section.
17
18       By default, a minimum millisecond threshold of 10 is used. If a thresh‐
19       old of 0 is used, all events are printed (warning: verbose).
20
21       Since this works by tracing the  ext4_file_operations  interface  func‐
22       tions, it will need updating to match any changes to these functions.
23
24       Since this uses BPF, only the root user can use this tool.
25

REQUIREMENTS

27       CONFIG_BPF and bcc.
28

OPTIONS

30       -p PID Trace this PID only.
31
32       min_ms Minimum  I/O  latency  (duration)  to  trace,  in  milliseconds.
33              Default is 10 ms.
34

EXAMPLES

36       Trace synchronous file reads and writes slower than 10 ms:
37              # ext4slower
38
39       Trace slower than 1 ms:
40              # ext4slower 1
41
42       Trace slower than 1 ms, and output just the fields in  parsable  format
43       (csv):
44              # ext4slower -j 1
45
46       Trace all file reads and writes (warning: the output will be verbose):
47              # ext4slower 0
48
49       Trace slower than 1 ms, for PID 181 only:
50              # ext4slower -p 181 1
51

FIELDS

53       TIME(s)
54              Time of I/O completion since the first I/O seen, in seconds.
55
56       COMM   Process name.
57
58       PID    Process ID.
59
60       T      Type of operation. R == read, W == write, O == open, S == fsync.
61
62       OFF_KB File offset for the I/O, in Kbytes.
63
64       BYTES  Size of I/O, in bytes.
65
66       LAT(ms)
67              Latency  (duration)  of I/O, measured from when it was issued by
68              VFS to the filesystem, to when it completed. This time is inclu‐
69              sive  of  block  device I/O, file system CPU cycles, file system
70              locks, run queue latency, etc. It's a more accurate  measure  of
71              the latency suffered by applications performing file system I/O,
72              than to measure this down at the block device interface.
73
74       FILENAME
75              A cached kernel file name (comes from dentry->d_iname).
76
77       ENDTIME_us
78              Completion timestamp, microseconds (-j only).
79
80       OFFSET_b
81              File offset, bytes (-j only).
82
83       LATENCY_us
84              Latency (duration) of the I/O, in microseconds (-j only).
85

OVERHEAD

87       This  adds  low-overhead  instrumentation  to  these  ext4  operations,
88       including  reads  and writes from the file system cache. Such reads and
89       writes can be very frequent (depending on the workload; eg, 1M/sec), at
90       which  point  the  overhead of this tool (even if it prints no "slower"
91       events) can begin to become significant. Measure  and  quantify  before
92       use.  If  this  continues to be a problem, consider switching to a tool
93       that prints in-kernel summaries only.
94
95       Note that the overhead of this tool should be less than  fileslower(8),
96       as  this  tool targets ext4 functions only, and not all file read/write
97       paths (which can include socket I/O).
98

SOURCE

100       This is from bcc.
101
102              https://github.com/iovisor/bcc
103
104       Also look in the bcc distribution for a  companion  _examples.txt  file
105       containing example usage, output, and commentary for this tool.
106

OS

108       Linux
109

STABILITY

111       Unstable - in development.
112

AUTHOR

114       Brendan Gregg
115

SEE ALSO

117       biosnoop(8), funccount(8), fileslower(8)
118
119
120
121USER COMMANDS                     2016-02-11                     ext4slower(8)
Impressum