It is important to know which version of Linux kernel you are running because many software or libraries require that certain kernel subsystems and features be available in order for them to run properly. Knowing the kernel version can also be helpful in diagnosing systems or debugging software problems.
If you would like to know which kernel version is running, you can check Linux kernel version by using uname command. In the example below, it shows that you are running a Linux kernel 2.6.32.
Another way to check Linux kernel version is via /proc/version.
Linux version 18.104.22.168-2.fc15.x86_64 (firstname.lastname@example.org) (gcc version 4.6.3 20120306 (Red Hat 4.6.3-2) (GCC) ) #1 SMP Tue May 8 11:09:22 UTC 2012
If you would like to know the version number of your Linux distribution (e.g., Debian, Ubuntu, CentOS, etc.), you can follow the distribution-specific instructions below.
To check Debian version number:
Debian GNU/Linux 5.0 \n \l
To check Ubuntu version number:
DISTRIB_ID=Ubuntu DISTRIB_RELEASE=10.04 DISTRIB_CODENAME=lucid DISTRIB_DESCRIPTION="Ubuntu 10.04.4 LTS"
Ubuntu 10.04.4 LTS \n \l
To check CentOS version number:
CentOS release 6.2 (Final)
To check RedHat version number:
Red Hat Enterprise Linux Server release 6.0 (Santiago)
To check Fedora version number:
Fedora release 14 (Laughlin)
To check OpenSuSE version number:
openSUSE 12.1 (x86_64) VERSION = 12.1 CODENAME = Asparagus
Subscribe to Xmodulo
Do you want to receive Linux FAQs, detailed tutorials and tips published at Xmodulo? Enter your email address below, and we will deliver our Linux posts straight to your email box, for free. Delivery powered by Google Feedburner.