How to check Linux Version
How to check Linux Version
a] /etc/*-release file.
b] lsb_release command.
c] /proc/version file.
Method #1: /etc/*-release file
To find out what version of Linux (distro) you are running, enter the following command at the shell prompt:
Sample output from my RHEL v5.x server:
$ cat /etc/*-release
Sample output from my RHEL v5.x server:
Red Hat Enterprise Linux Server release 5 (Tikanga)Sample outputs from my Ubuntu Linux v7.10 server:
DISTRIB_ID=Ubuntu DISTRIB_RELEASE=7.10 DISTRIB_CODENAME=gutsy DISTRIB_DESCRIPTION="Ubuntu 7.10"
Method #2: lsb_release Command To Find Out Linux Distribution Name/Version
The lsb_release command displays certain LSB (Linux Standard Base) and distribution-specific information. Type the following command:
Sample outputs:
$ lsb_release -a
Sample outputs:
No LSB modules are available. Distributor ID: Debian Description: Debian GNU/Linux 6.0.1 (squeeze) Release: 6.0.1 Codename: squeeze
How Do I Find Out My Kernel Version?
Type the following command:
OR
Sample outputs:
$ uname -a
OR
$ uname -mrs
Sample outputs:
Where,
- Linux – Kernel name
- 2.6.32-5-amd64 – Kernel version number
- x86_64 – Machine hardware name (64 bit)
Say hello to /proc/version
Type the following command to see kernel version and gcc version used to build the same:
Sample outputs:
$ cat /proc/version
Sample outputs:
Linux version 3.2.0-0.bpo.1-amd64 (Debian 3.2.4-1~bpo60+1) ([email protected]) (gcc version 4.4.5 (Debian 4.4.5-8) ) #1 SMP Sat Feb 11 08:41:32 UTC 2012
Tidak ada komentar :
Posting Komentar