We're sorry but this page doesn't work properly without JavaScript enabled. Please enable it to continue.
Feedback

Profiling the FreeBSD kernel boot

Formal Metadata

Title
Profiling the FreeBSD kernel boot
Subtitle
From hammer_time to start_init
Title of Series
Number of Parts
45
Author
License
CC Attribution 3.0 Unported:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal purpose as long as the work is attributed to the author in the manner specified by the author or licensor.
Identifiers
Publisher
Release Date
Language

Content Metadata

Subject Area
Genre
Abstract
I will describe work I did to profile the FreeBSD kernel boot — both adding instrumentation to the kernel to collect data while the system is booting, and converting the resulting timestamp records into a graphical visualization of where time is spent in the boot process. I will show results from some systems and highlight places where it is clear that the performance of the FreeBSD boot process can be improved. Many users have complained over the years about the time it takes for FreeBSD to boot, but little work has been done until now to investigate this. Unfortunately it is difficult to profile the very beginning of the FreeBSD boot process; as a result, in late 2017 I introduced a new "TSLOG" framework for recording timestamps at points in the kernel boot. I will explain why existing mechanisms were insufficient and how the TSLOG framework operates, and how I utilized the TSLOG framework to annotate key parts of the FreeBSD kernel boot process. Finally, I will explain the process of converting logged timestamps from the kernel boot into a "flame chart". The audience is expected to be generally familiar with C, but an understanding of FreeBSD kernel internals will not be assumed.