如何检查内核中是否启用了SMP?

编程入门 行业动态 更新时间:2024-10-23 10:26:52
本文介绍了如何检查内核中是否启用了SMP?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我想知道如何在运行的机器上检查内核是否配置为SMP?当然,我可以查看内核 .config 文件并进行搜索.但是,问题是说我没有源代码,如何检查SMP配置?是否有任何 proc 文件进行检查?

I was wondering how can I check on my running machine, whether the kernel is configured for SMP or not? Of course, I can look into the kernel .config file and can search for it. But, the question is let's say I don't have a source code, how will I check the SMP configuration? Is there any proc file to check it?

以下内容表明我没有多核:

The following says that I have no multi-cores:

#cat /proc/cpuinfo processor : 1 cpu model : Broadcom BMIPS5000 V1.1 FPU V0.1 BogoMIPS : 651.26 cpu MHz : 1305.018 wait instruction : yes microsecond timers : yes tlb_entries : 64 extra interrupt vector : yes hardware watchpoint : no ASEs implemented : shadow register sets : 1 kscratch registers : 0 core : 0 VCED exceptions : not available VCEI exceptions : not available

uname -a 的输出说:

Linux 136.170.193.3 3.3.8-2.4 #2 SMP Fri Dec 13 07:11:03 EST 2013 mips GNU/Linux

这里有点令人困惑.评论中的某人建议我检查 uname -a .我不确定结果是否可靠.我是否可以假设使用 uname -a 生成的关键字SMP,将内核配置为SMP?

A bit confusing here. Someone on the comments suggested me to check uname -a . I am not sure whether the results are reliable or not. Can I assume that with the keyword SMP produced by uname -a, the kernel is configured as SMP?

推荐答案

我可以假设用uname -a产生的关键字SMP,内核是配置为SMP?

Can I assume that with the keyword SMP produced by uname -a, the kernel is configured as SMP?

是的.uname返回的版本字符串是在编译内核时生成的.

Yes. The version string returned by uname is generated when kernel is compiled.

更多推荐

如何检查内核中是否启用了SMP?

本文发布于:2023-11-01 01:24:34,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1547841.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:内核   SMP

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!