如何找到linux处理器/芯片架构
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/7066625/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to find the linux processor / chip architecture
提问by Jason
What command should I use to find the linux processor / chip architecture?
我应该使用什么命令来查找 linux 处理器/芯片架构?
linux-x86-32
linux-x86-64
linux-ppc-64
采纳答案by joet3ch
To display kernel architecture: uname -a
显示内核架构: uname -a
To display cpu details: cat /proc/cpuinfo
要显示 CPU 详细信息: cat /proc/cpuinfo
回答by Hyman
see (man uname
):
见(man uname
):
echo `uname -s`-`uname -p`
回答by Montells
type in terminal:
在终端输入:
lscpu
逻辑处理器
return this output:
返回此输出:
Architecture: i686
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 2
On-line CPU(s) list: 0,1
Thread(s) per core: 1
Core(s) per socket: 2
Socket(s): 1
Vendor ID: GenuineIntel
CPU family: 6
Model: 23
Stepping: 6
CPU MHz: 2670.000
BogoMIPS: 5320.13
L1d cache: 32K
L1i cache: 32K
L2 cache: 3072K
or type in terminal
或输入终端
lscpu | grep Architecture
lscpu | grep 架构
return this output:
返回此输出:
Architecture: i686
回答by James Ko
I'm surprised no one suggested uname -m
. On my laptop, this gives armv7l
, while uname -a
gives me a monstrous 2 lines of text.
我很惊讶没有人建议uname -m
。在我的笔记本电脑上,这给了armv7l
,而uname -a
给了我一个可怕的 2 行文本。
回答by infoclogged
The best and concise is the command
最好最简洁的是命令
hostnamectl
It gives you the most basic information about your machine. The others like uname, lsb_release, lscpu etc returns specific information.
它为您提供有关机器的最基本信息。其他如 uname、lsb_release、lscpu 等返回特定信息。
Static hostname: xxxx
Icon name: computer-laptop
Chassis: laptop
Boot ID: b3a1f952c514411c8c4xxxxxxxxxxxx
Operating System: Ubuntu 14.04.3 LTS
Kernel: Linux 3.19.0-43-generic
Architecture: x86_64