KLDXREF(8)

πŸ“¦
version 15.1 Β· 2 versions
, in freebsd 15.1, nixpkgs unstable

πŸ’– KLDXREF(8) β€” the girl's guide to kldxref πŸ’–

ok so like. this is the System Manager's Manual page for kldxref, and bestie, it's giving "quiet little utility that actually runs the whole show." stay with me 🫢


✨ NAME ✨

kldxref β€” generate hints for the kernel loader


🌸 SYNOPSIS 🌸

kldxref [-Rdv] [-f hintsfile] path ...

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so the kldxref utility is used to generate hint files which list modules, their version numbers, and the files that contain them πŸ‘‘. these hints are used by the kernel loader to determine where to find a particular KLD module. like, it's the little matchmaker that tells the loader where your module lives πŸ’….

a separate hint file is generated for each directory listed on the command line that contains modules. and here's the part where it gets a little spicy 😭 β€” if no hint records are generated for a particular directory, no hint file is created, and the preexisting hint file (if there was one in that directory) is removed. so like, no records = no file = old file gone. periodt.

kldxref only processes files that either have no dots in their name like kernel or that end in β€œ.ko” like foo.ko. everything else? not invited to the party πŸ™ˆ.

the following options are available:


πŸŽ€ OPTIONS πŸŽ€

  • -R β€” recurse into subdirectories. go deeper bestie, the modules are down there 🌈
  • -d β€” do not generate a hint file, but print module metadata on standard output. just look, don't touch πŸ‘€
  • -f hintsfile β€” specify a different name for the hints files than linker.hints. custom name, custom vibe ✨
  • -v β€” operate in verbose mode. she's talking now πŸ’¬

⭐ EXAMPLES ⭐

to build hint files for both standard and add-on modules:

kldxref /boot/kernel /boot/modules

to build hint files for all installed kernels:

kldxref -R /boot

ate, no crumbs πŸ“


πŸ”₯ SEE ALSO πŸ”₯

kld(4), kldconfig(8), kldload(8), kldstat(8), kldunload(8)

like, the whole kld friend group. iykyk πŸ’œ


πŸ’« HISTORY πŸ’«

the kldxref utility first appeared in FreeBSD 5.0. an icon, a legend, and she's been serving since day one πŸ‘‘


πŸ’… AUTHORS πŸ’…

the kldxref utility was implemented by Boris Popov <bp@FreeBSD.org>. this manual page was written by Boris Popov <bp@FreeBSD.org> and Dag-Erling Smørgrav <des@FreeBSD.org>. we stan 🫢


ok that's the whole page, every flag, every path, every warning β€” nothing skipped, nothing invented, just with way better energy πŸ’–

and like, sourcing details for the record: this one's from the Debian folks, dated February 25, 2023, and it's the KLDXREF(8) page in the System Manager's Manual. mwah, bye bestie πŸ’‹πŸŽ€

πŸ“¦ where this page comes from