FREEBSD-VERSION(1)
π¦ freebsd-version π¦
okay bestie, so this is the freebsd-version command from the General Commands Manual, and it's literally the glow-up you need when you wanna know what version of FreeBSD you're running π
β¨ NAME β¨
freebsd-version β print the version and patch level of the installed system
π SYNOPSIS π
freebsd-version [-kru] [-j jail]
π DESCRIPTION π
The freebsd-version utility makes a best effort to determine the version and patch level of the installed kernel and / or userland. no cap, it's out here doing its absolute best to figure out what you're running π«Ά
The following options are available:
-kβ Print the version and patch level of the installed kernel. Unlikeuname(1), if a new kernel has been installed but the system has not yet rebooted,freebsd-versionwill print the version and patch level of the new kernel. it's giving "new kernel who dis" energy fr fr π-rβ Print the version and patch level of the running kernel. Unlikeuname(1), this is unaffected by environment variables. literally immune to the vibes of your env vars, iconic β¨-uβ Print the version and patch level of the installed userland. These are hardcoded intofreebsd-versionduring the build. baked right in like it's a personality trait π-jjailβ Print the version and patch level of the installed userland in the given jail specified byjidorname. This option can be specified multiple times. yes bestie you can stack 'em, go off π
If several of the above options are specified, freebsd-version will print the installed kernel version first, then the running kernel version, next the userland version, and finally the userland version of the specified jails, on separate lines. order matters, it's not out here just vibing randomly π If no option is specified, it will print the userland version only. default behavior? just the userland, keeping it simple.
π§ IMPLEMENTATION NOTES π§
The freebsd-version utility should provide the correct answer in the vast majority of cases, including on systems kept up-to-date using freebsd-update(8), which does not update the kernel version unless the kernel itself was affected by the latest patch. so like, freebsd-update(8) is out here doing its thing but it's not touching the kernel version unless the kernel was literally affected, periodt π
To determine the name (and hence the location) of a custom kernel, the freebsd-version utility will attempt to parse /boot/defaults/loader.conf and /boot/loader.conf, looking for definitions of the kernel and bootfile variables, both with a default value of "kernel". It may however fail to locate the correct kernel if either or both of these variables are defined in a non-standard location, such as in /boot/loader.rc. so like, if you're being extra and putting your configs in weird places, it might not find your kernel and that's just how it is π no cap, it's trying its best but it can't read your mind.
π ENVIRONMENT π
ROOTβ Path to the root of the filesystem in which to look forloader.confand the kernel. this is your "look over here instead" vibes π₯
β EXAMPLES β
To determine the version of the currently running userland:
/bin/freebsd-version -u
To inspect a system being repaired using a live system:
mount -rt ufs /dev/ada0p2 /mnt
env ROOT=/mnt /mnt/bin/freebsd-version -ku
like, you're mounting the thing and then checking the version from the mounted root, it's giving repair mode main character energy π«Ά
πΈ SEE ALSO πΈ
π HISTORY π
The freebsd-version command appeared in FreeBSD 10.0. so it's been around for a minute, not a newbie bestie π
π AUTHORS π
The freebsd-version utility and this manual page were written by Dag-Erling SmΓΈrgrav <des@FreeBSD.org>. shoutout to the icon who made this happen π
and that's the whole vibe bestie β¨ this page? it's from Debian, dated August 27, 2025, and it's literally your fave manual page now, no cap π
π¦ where this page comes from
- freebsd 15.1: base 15.1
- Copyright (c) 2013 Dag-Erling SmΓΈrgrav
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms