Today's article has you counting processors, cores, or threads really...

KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,455
Reaction score
5,719
Credits
51,944


f33dm3bits

Gold Member
Gold Supporter
Joined
Dec 11, 2019
Messages
4,790
Reaction score
3,442
Credits
34,904
Isn't it juse easier to search how many cores your cpu has?
Code:
grep cores /proc/cpuinfo| head -n1
cpu cores    : 8
 

Brickwizard

Well-Known Member
Joined
Apr 28, 2021
Messages
2,666
Reaction score
1,768
Credits
19,952
OP
K

KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,455
Reaction score
5,719
Credits
51,944
I have....
inxi -c

Yup, there's another one. There's also lscpu | grep "per socket" which should give an accurate result.

There's a ton of ways to get this data. The article contains only a few.
 

dos2unix

Well-Known Member
Joined
May 3, 2019
Messages
1,448
Reaction score
1,053
Credits
8,951
lshw -c cpu | grep config
configuration: cores=12 enabledcores=12 threads=24

cpuinfo | grep Count
Count: 24

lscpu | grep Core
Model name: AMD Ryzen 9 3900X 12-Core Processor
BIOS Model name: AMD Ryzen 9 3900X 12-Core Processor Unknown CPU @ 3.8GHz
Core(s) per socket: 12
 
OP
K

KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,455
Reaction score
5,719
Credits
51,944
Y'all can free to add it to the article as a comment. ;-)

I'm now kinda curious as to how many possible ways you can get this information - probably excluding any GUI ways... If we include graphical applications, it's a bunch.
 

f33dm3bits

Gold Member
Gold Supporter
Joined
Dec 11, 2019
Messages
4,790
Reaction score
3,442
Credits
34,904
By the way, the article invites you to leave your method as a comment. ;-)
I just replied with a comment but my code tags don't work, and when I login to the backend it won't allow me to edit my comment.
 
OP
K

KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,455
Reaction score
5,719
Credits
51,944
Hmm... I don't think you have the rights to edit comments. Code tags are <code></code> over there. I'll take a peek at it in a moment. I'm just now really getting here for the day.
 
OP
K

KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,455
Reaction score
5,719
Credits
51,944
You now have 15 minutes to edit comments after submitting them. It's a fairly obvious feature, appearing after you submit your comment.
 
$100 Digital Ocean Credit
Get a free VM to test out Linux!

Linux.org Hosting Donations
Consider making a donation

Members online


Top