linux怎么64位,在linux下如何查看CPU是否支持64位
在linux下如何查看CPU是否支持64位的方法是:
# grep "flags" /proc/cpuinfo
flags?????????? : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc pni monitor ds_cpl vmx smx est tm2 cx16 xtpr lahf_lm
flags?????????? : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc up pni monitor ds_cpl vmx smx est tm2 cx16 xtpr lahf_lm
如果flags中有lm,則表示支持64位,lm的意思是long mode。
# uname -a
Linux euis1 2.6.9-55.ELsmp #1 SMP Fri Apr 20 17:03:35 EDT 2007 i686 i686 i386 GNU/Linux
(查看當前操作系統內核信息)
# cat /etc/issue | grep Linux
Red Hat Enterprise Linux AS release 4 (Nahant Update 5)
(查看當前操作系統發行版信息)
# cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c
8Intel(R) Xeon(R) CPU??????????? E5410?? @ 2.33GHz
(看到有8個邏輯CPU, 也知道了CPU型號)
# cat /proc/cpuinfo | grep physical | uniq -c
4physical id????? : 0
4physical id????? : 1
(說明實際上是兩顆4核的CPU)
# getconf LONG_BIT
32
(說明當前CPU運行在32bit模式下, 但不代表CPU不支持64bit)
# cat /proc/cpuinfo | grep flags | grep ' lm ' | wc -l
8
(結果大于0, 說明支持64bit計算. lm指long mode, 支持lm則是64bit)
==========================
$su - root
#file /sbin/init
/sbin/init: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked (uses shared libs), for GNU/Linux 2.6.9, stripped
You have new mail in /var/spool/mail/root
即是32位的 linux, 如是64位的, 顯示的是 64-bit
================
LINUX
# uname -a
Linux DELL2950 2.6.5-7.244-smp #1 SMP Mon Dec 12 18:32:25 UTC 2005 i686 i686
后面是 X686或X86_64則內核是64位的,i686或i386則內核是32位的
AIX:
顯示AIX系統內核是32位還是64位:
bootinfo -K
顯示機器硬件是32位還是64位:
bootinfo -y
SUN:
$isainfo -bv
64表示內核是64位的,32表示內核是32位的
HPUX:
>getconf KERNEL_BITS
64表示內核是64位的,32表示內核是32位的
另外的方法:
getconf LONG_BIT
總結
以上是生活随笔為你收集整理的linux怎么64位,在linux下如何查看CPU是否支持64位的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Android Studio主题设置、颜
- 下一篇: linux 基因组数据下载,linux下