GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
FREEBSD-VERSION(1) FreeBSD General Commands Manual FREEBSD-VERSION(1)

freebsd-version
print the version and patch level of the installed system

freebsd-version [-kru] [-j jail]

The freebsd-version utility makes a best effort to determine the version and patch level of the installed kernel and / or userland.

The following options are available:

Print the version and patch level of the installed kernel. Unlike uname(1), if a new kernel has been installed but the system has not yet rebooted, freebsd-version will print the version and patch level of the new kernel.
Print the version and patch level of the running kernel. Unlike uname(1), this is unaffected by environment variables.
Print the version and patch level of the installed userland. These are hardcoded into freebsd-version during the build.
jail
Print the version and patch level of the installed userland in the given jail specified by jid or name. This option can be specified multiple times.

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. If neither is specified, it will print the userland version only.

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.

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.

Path to the root of the filesystem in which to look for loader.conf and the kernel.

To determine the version of the currently running userland:
/bin/freebsd-version -u

To inspect a system being repaired using a live CD:

mount -rt ufs /dev/ada0p2 /mnt
env ROOT=/mnt /mnt/bin/freebsd-version -ku

uname(1), loader.conf(5)

The freebsd-version command appeared in FreeBSD 10.0.

The freebsd-version utility and this manual page were written by Dag-Erling Smørgrav <des@FreeBSD.org>.
October 1, 2021 FreeBSD 13.1-RELEASE

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.