ubuntu系统中怎么查看cpu型号和频率?

2024年 6月 7日 109.8k 0

在Ubuntu上查看CPU型号和频率的方法有很多。以下是几种常用的方法:

1. 使用 lscpu 命令

lscpu 命令会显示有关CPU的信息,包括型号和频率。

lscpu

Architecture:        x86_64

CPU op-mode(s):      32-bit, 64-bit

Byte Order:          Little Endian

CPU(s):              4

On-line CPU(s) list: 0-3

Thread(s) per core:  2

Core(s) per socket:  2

Socket(s):           1

NUMA node(s):        1

Vendor ID:           GenuineIntel

CPU family:          6

Model:               142

Model name:          Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz

Stepping:            10

CPU MHz:             2112.004

CPU max MHz:         4200.0000

CPU min MHz:         400.0000

2. 查看 /proc/cpuinfo 文件

/proc/cpuinfo 文件包含有关CPU的详细信息。

cat /proc/cpuinfo

输出示例:

processor   : 0

vendor_id   : GenuineIntel

cpu family  : 6

model       : 142

model name  : Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz

stepping    : 10

microcode   : 0xde

cpu MHz     : 2112.004

cache size  : 8192 KB

physical id : 0

siblings    : 4

core id     : 0

cpu cores   : 2

apicid      : 0

initial apicid  : 0

fpu         : yes

fpu_exception : yes

cpuid level : 22

wp          : yes

flags       : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb invpcid_single pti ssbd ibrs ibpb stibp tpr_shadow vnmi flexpriority ept vpid fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid mpx rdseed adx smap clflushopt intel_pt xsaveopt xsavec xgetbv1 xsaves dtherm ida arat pln pts hwp hwp_notify hwp_act_window hwp_epp md_clear flush_l1d

bugs        : spectre_v1 spectre_v2 spec_store_bypass l1tf mds swapgs

bogomips    : 4224.00

clflush size    : 64

cache_alignment : 64

address sizes   : 39 bits physical, 48 bits virtual

power management:

3. 使用 dmidecode 命令dmidecode 命令可以获取更多关于硬件的信息,包括CPU的型号和频率。

sudo dmidecode -t processor

输出示例:

# dmidecode 3.2

Getting SMBIOS data from sysfs.

SMBIOS 2.8 present.

Handle 0x0040, DMI type 4, 42 bytes

Processor Information

    Socket
Designation: U3E1

    Type: Central Processor

    Family: Core i7

   
Manufacturer: Intel(R) Corporation

    ID: EA 06 08 00 FF FB EB BF

   
Signature: Type 0, Family 6, Model 142, Stepping 10

    Flags:

        FPU
(Floating-point unit on-chip)

        VME (Virtual mode extension)

       
DE (Debugging extension)

        PSE (Page size extension)

        TSC
(Time stamp counter)

        MSR (Model specific registers)

        PAE
(Physical address extension)

        MCE (Machine check exception)

       
CX8 (CMPXCHG8 instruction supported)

        APIC (On-chip APIC hardware
supported)

        SEP (Fast system call)

        MTRR (Memory type range
registers)

        PGE (Page global enable)

        MCA (Machine check
architecture)

        CMOV (Conditional move instruction
supported)

        PAT (Page attribute table)

        PSE-36 (36-bit page
size extension)

        CLFSH (CLFLUSH instruction supported)

        DS
(Debug store)

        ACPI (ACPI supported)

        MMX (MMX technology
supported)

        FXSR (FXSAVE and FXSTOR instructions supported)

       
SSE (Streaming SIMD extensions)

        SSE2 (Streaming SIMD extensions
2)

        SS (Self-snoop)

        HTT (Multi-threading)

        TM
(Thermal monitor supported)

        PBE (Pending break enabled)

   
Version: Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz

    Voltage: 0.7 V

   
External Clock: 100 MHz

    Max Speed: 4200 MHz

    Current Speed: 2112
MHz

    Status: Populated, Enabled

    Upgrade: Other

    L1 Cache
Handle: 0x0041

    L2 Cache Handle: 0x0042

    L3 Cache Handle:
0x0043

    Serial Number: To Be Filled By O.E.M.

    Asset Tag: To Be
Filled By O.E.M.

    Part Number: To Be Filled By O.E.M.

    Core Count:
4

    Thread Count: 8

    Characteristics:

        64-bit
capable

这些方法可以帮助你详细了解Ubuntu系统上CPU的型号和频率,从而进行性能监控和优化。

相关文章

服务器端口转发,带你了解服务器端口转发
服务器开放端口,服务器开放端口的步骤
产品推荐:7月受欢迎AI容器镜像来了,有Qwen系列大模型镜像
如何使用 WinGet 下载 Microsoft Store 应用
百度搜索:蓝易云 – 熟悉ubuntu apt-get命令详解
百度搜索:蓝易云 – 域名解析成功但ping不通解决方案

发布评论