Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Possible Duplicate:
How do I find out what version of Linux I’m running?

I need to find out some information about the server os I'm working on.

The release version (e.g. 9.04 if Ubuntu or 4 if RHEL) is important to me and the command uname doesn't show it.

$ uname -a
Linux xxxxxxx 2.6.9-78.0.22.EL #1 Fri Feb 31 25:71:00 EDT 2009 x86_64 GNU/Linux

So: How to get this information via a commandline command?

share|improve this question

marked as duplicate by jtimberman, BinaryMisfit Aug 25 '09 at 16:13

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

Duplicate:… – jtimberman Aug 25 '09 at 14:36
up vote 7 down vote accepted

Most (if not all) modern distributions will include the lsb_release command.

heillinr@mojojojo:~$ lsb_release -r
Release:    9.04
heillinr@mojojojo:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 9.04
Release:    9.04
Codename:   jaunty

Should give you what you are after :)

share|improve this answer

What do you have in /etc/*-release? I have /etc/lsb-release which contains:


share|improve this answer


cat /etc/lsb-release

share|improve this answer

I didn't know about lsb_release.

My method for RPM based systems was:

$ rpm -qa | grep release
share|improve this answer

in addition to lsb-release (which is available as lsb-release package under debian), you can look at /etc/debian_version(for debian and derivatives) and /etc/issue for most other distributions.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged .