Objective
Since the use of Linux is not often, whenever the use of the installation software, install the software should choose the installation package platform, is 32-bit or 64-bit. At this time suddenly found do not know how to check, so Baidu. Although Baidu is easy to come out, but still no own notes look comfortable. So, it's still recorded.
Identification criteria
The first thing to know is what the logo is 32-bit and what is 64-bit.
PC Server X86 Series
i386--i686 are all 32-bit
x86_64 is 64-bit
View the number of digits command
The order is really not too much, in order to prevent selectivity barriers, the first approach is chosen uniformly, followed only as a supplement.
Method 1:
[[email protected] ~]# uname -aLinux bogon 3.10.0-327.18.2.el7.x86_64 #1 SMP Thu May 12 11:03:55 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Method 2: Display System program information
file /bin/ls/bin/ls: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.32, BuildID[sha1]=aa7ff68f13de25936a098016243ce57c3c982e06, stripped
Method 3:
[[email protected] ~]# cat /proc/versionLinux version 3.10.0-327.18.2.el7.x86_64 ([email protected]) (gcc version 4.8.3 20140911 (Red Hat 4.8.3-9) (GCC) ) #1 SMP Thu May 12 11:03:55 UTC 2016
Method 4:
(the int type and long type are generally 4 bytes in a 32-bit system, and the int type in the 64-bit system is still 4 bytes, but long has become a 8-byte inux "getconf word_bit" is available in the system and
"Getconf long_bit" gets the number of digits for word and LONG. 64-bit systems should be 32 and 64, respectively. )
[[email protected] ~]# getconf LONG_BIT64
Viewing the system version
Method 1:
[Email protected] ~]#Lsb_release-ALsbVersion:: Core-4.1-amd64: Core-4.1-noarch: Cxx-4.1-amd64: Cxx-4.1-noarch:d ESKTOP-4.1-AMD64:d Esktop-4.1-noarch: languages-4.1-amd64: Languages-4.1-noarch:p rinting-4.1-amd64:p rinting-4.1-noarch Distributor ID: centosDescription: centos Linux release 7. 2. 1511 (Core) Release:7. 2. 1511codename: Core
Method 2:
[[Email protected] ~]# Cat/etc/os-releaseName="CentOS Linux"version="7 (Core)"Id="CentOS"Id_like= "Rhel Fedora" version_id= "7" pretty_name= "CentOS Linux 7 (Core)" ansi_color = "0;31" cpe_name= "Cpe:/o:centos: Centos:7 "home_url=" https://www.centos.org/" bug_report_url= "https://bugs.centos.org/" centos_mantisbt_project= "CentOS-7" Centos_mantisbt_project_version= "7" redhat_support_product=< Span class= "hljs-string" > "CentOS" redhat_support_product_version= "7"
Method 3:
[[email protected] ~]# cat /etc/redhat-releaseCentOS Linux release 7.2.1511 (Core)
Method 4:
[[email protected] ~]# rpm -q centos-releasecentos-release-7-2.1511.el7.centos.2.10.x86_64
View Kernel version
Method 1:
[[email protected] ~]# cat /proc/versionLinux version 3.10.0-327.18.2.el7.x86_64 ([email protected]) (gcc version 4.8.3 20140911 (Red Hat 4.8.3-9) (GCC) ) #1 SMP Thu May 12 11:03:55 UTC 2016
Method 2:
[[email protected] ~]# uname -aLinux bogon 3.10.0-327.18.2.el7.x86_64 #1 SMP Thu May 12 11:03:55 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Reference
CentOS 7 System View system version and number of machine bits