Categories
CentOS

How to Find Your CentOS Version

Someone’s given you a CentOS server to do some work on, perhaps putting up a website. “What version of CentOS is it running?”, you ask. “I don’t know” is a pretty common answer, or “version 5, I think”.

The CentOS version tends to indicate the rough age of the software (e.g. Linux kernel, PHP, MySQL) you’ll be using.

Here’s how you can check the CentOS version directly.

Find the CentOS Version

If you want to know what version of CentOS its running.

To check, cat the /etc/issue file:

[root@bijango ~]# cat /etc/issue
CentOS release 5.3 (Final)
Kernel \r on an \m

Note the contents of /etc/issue is displayed when someone creates a terminal session on the server,
so the system administrator may have edited this file to put in a different message, and potentially deleted the CentOS version information.

This was of checking the Linux distro version was tested on CentOS 5.2, CentOS 5.3, Ubuntu 8.10 and Ubuntu 10.10.

This way of checking the OS version would probably work on Red Hat Enterprise Linux and Debian as well. This is because CentOS is a clone of Red Hat, and Ubuntu is derived from Ubuntu.