blob: b49495101cf47a3cea860e737fea15d86c274e1e [file] [log] [blame] [view]
James Hawkinsabd73e62016-01-19 15:10:38 -08001# bootstat #
2
3The bootstat command records boot events (e.g., `firmware_loaded`,
4`boot_complete`) and the relative time at which these events occurred. The
5command also aggregates boot event metrics locally and logs the metrics for
6analysis.
7
8 Usage: bootstat [options]
9 options include:
10 -d Dump the boot event records to the console.
11 -h Show this help.
12 -l Log all metrics to logstorage.
13 -r Record the relative time of a named boot event.
14
15## Relative time ##
16
17The timestamp recorded by bootstat is the uptime of the system, i.e., the
18number of seconds since the system booted.
19
20## Recording boot events ##
21
22To record the relative time of an event during the boot phase, call `bootstat`
23with the `-r` option and the name of the boot event.
24
25 $ bootstat -r boot_complete
26
27The relative time at which the command runs is recorded along with the name of
28the boot event to be persisted.
29
30## Logging boot events ##
31
32To log the persisted boot events, call `bootstat` with the `-l` option.
33
34 $ bootstat -l
35
36bootstat logs all boot events recorded using the `-r` option to the EventLog
37using the Tron histogram. On GMS devices these logs are uploaded via Clearcut
38for aggregation and analysis.
39
40## Printing boot events ##
41
42To print the set of persisted boot events, call `bootstat` with the `-p` option.
43
44 $ bootstat -p
45 Boot events:
46 ------------
47 boot_complete 71