Skip to main content
Removed information around cat /etc/proc as it's unneeded and this continues to provide the most general way of obtaining distro info.
Source Link
rwc
  • 861
  • 5
  • 7

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

Also going to echo another poster's suggestion too (it will pull a bit more detailed information):

$ cat /proc/version
Linux version 3.0.0-14-server (buildd@allspice) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #23-Ubuntu SMP Mon Nov 21 20:49:05 UTC 2011

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

Also going to echo another poster's suggestion too (it will pull a bit more detailed information):

$ cat /proc/version
Linux version 3.0.0-14-server (buildd@allspice) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #23-Ubuntu SMP Mon Nov 21 20:49:05 UTC 2011

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

Also going to echo another poster's suggestion totoo (It'llit will pull a bit more detailed information):

$ cat /proc/version
Linux version 3.0.0-14-server (buildd@allspice) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #23-Ubuntu SMP Mon Nov 21 20:49:05 UTC 2011

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

Also going to echo another poster's suggestion to (It'll pull a bit more detailed information):

$ cat /proc/version
Linux version 3.0.0-14-server (buildd@allspice) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #23-Ubuntu SMP Mon Nov 21 20:49:05 UTC 2011

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

Also going to echo another poster's suggestion too (it will pull a bit more detailed information):

$ cat /proc/version
Linux version 3.0.0-14-server (buildd@allspice) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #23-Ubuntu SMP Mon Nov 21 20:49:05 UTC 2011
added 279 characters in body
Source Link
rwc
  • 861
  • 5
  • 7

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

Also going to echo another poster's suggestion to (It'll pull a bit more detailed information):

$ cat /proc/version
Linux version 3.0.0-14-server (buildd@allspice) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #23-Ubuntu SMP Mon Nov 21 20:49:05 UTC 2011

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

You'll want to use:

$ cat /etc/*-release

You'll get a response similar to this:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.10
DISTRIB_CODENAME=oneiric
DISTRIB_DESCRIPTION="Ubuntu 11.10"

Also going to echo another poster's suggestion to (It'll pull a bit more detailed information):

$ cat /proc/version
Linux version 3.0.0-14-server (buildd@allspice) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #23-Ubuntu SMP Mon Nov 21 20:49:05 UTC 2011
Source Link
rwc
  • 861
  • 5
  • 7
Loading