Find out the Linux name, version and kernel details

Source: Internet
Author: User

This short tutorial are intended to help newbies who don ' t know what to find out the Linux distribution name, version and Ke Rnel details via command line.

Method 1–distribution & Version Details

Command:

Cat/etc/*-release

Sample Output on CentOS 6.4:

CentOS Release 6.4 (Final)

Sample Output on Ubuntu 13.04:

distrib_id=ubuntudistrib_release=13.04distrib_codename=raringdistrib_description= "Ubuntu 13.04" NAME= "Ubuntu" Version= "13.04, Raring ringtail" id=ubuntuid_like=debianpretty_name= "Ubuntu 13.04" version_id= "13.04" home_url= "http ://www.ubuntu.com/"support_url=" http://help.ubuntu.com/"bug_report_url=" http://bugs.launchpad.net/ubuntu/"

Sample Output on Debian 7:

Pretty_name= "Debian Gnu/linux 7 (wheezy)" name= "Debian Gnu/linux" version_id= "7" version= "7 (wheezy)" Id=debianansi_ Color= "1;31" home_url= "http://www.debian.org/" support_url= "http://www.debian.org/support/" bug_report_url= "http ://bugs.debian.org/"

Method Distribution & Version Details

Command:

Lsb_release-a

Sample Output on Debian 7:

No LSB modules is available. Distributor ID:DebianDescription:Debian Gnu/linux 7.1 (wheezy) Release:7.1codename:wheezy

Sample Output on Ubuntu 13.04:

No LSB modules is available. Distributor ID:UbuntuDescription:Ubuntu 13.04release:13.04codename:raring

Method 3–finding Kernel Version

Command:

Cat/proc/version

Sample Output on CentOS 6.4:

Linux version 2.6.32-358.11.1.el6.centos.plus.i686 ([email protected]) (GCC version 4.4.6 20120305 (Red Hat 4.4.6-4) (GCC) ) #1 SMP Wed June 17:07:23 UTC 2013

Sample Output on Debian 7:

Linux version 3.2.0-4-486 (Debian-ker[email protected]) (GCC version 4.6.3 (Debian 4.6.3-14)) #1 Debian 3.2.46-1

Sample Output on Ubuntu 13.04:

Linux version 3.8.0-29-generic ([email protected]) (GCC version 4.7.3 (Ubuntu/linaro 4.7.3-1ubuntu1)) #42-ubuntu SMP Tue 19:40:39 UTC 2013

Method 4–finding Kernel Version

Command:

Uname-a

Sample Output on CentOS 6.4:

Linux server.unixmen.com 2.6.32-358.11.1.el6.centos.plus.i686 #1 SMP Wed June 17:07:23 UTC to i686 i686 i386 Gnu/linux M

Sample output on Debian 7:

Linux server 3.2.0-4-486 #1 Debian 3.2.46-1 i686 gnu/linux

Sample Output on Ubuntu 13.04:

Linux SK 3.8.0-29-generic #42-ubuntu SMP Tue 19:40:39 UTC x86_64 x86_64 x86_64 gnu/linux

Method 5–finding Distribution Name

Command:

Cat/etc/redhat-release

Sample Output on CentOS 6.4/rhel 6.4:

CentOS Release 6.4 (Final)

Method 6–finding Distribution version

Command:

Cat/etc/debian_version

Sample Output on Debian 7:

7.1

Sample Output on Ubuntu 13.04:

Wheezy/sid

Method 7–finding distribution Name & Version

Command:

Cat/etc/issue

Sample Output on Ubuntu 13.04:

Ubuntu 13.04 \ \l

Sample Output on Debian 7:

Debian Gnu/linux 7 \ \l

Sample Output on CentOS 6.4:

CentOS Release 6.4 (Final) Kernel \ r on a \m

For other distributons

I didn ' t not check the following commands yet, because I don ' t has the respective systems at the time writing this. I gathered these details on various websites. Hope it helps you.

Novel SUSE:

Cat/etc/suse-release

Fedora:

Cat/etc/fedora-release

Slackware:

Cat/etc/slackware-releasecat/etc/slackware-version

Mandrake:

Cat/etc/mandrake-release

Yellow Dog:

Cat/etc/yellowdog-release

Sun JDS:

Cat/etc/sun-release

Solaris/sparc:

Cat/etc/release

Gentoo:

Cat/etc/gentoo-release


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.