ubuntu:cpu:display_the_number_of_processors
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
ubuntu:cpu:display_the_number_of_processors [2020/07/15 09:30] – external edit 127.0.0.1 | ubuntu:cpu:display_the_number_of_processors [2021/06/22 11:22] (current) – peter | ||
---|---|---|---|
Line 2: | Line 2: | ||
To display the number of CPUs. | To display the number of CPUs. | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Using / | ||
<code bash> | <code bash> | ||
Line 7: | Line 11: | ||
</ | </ | ||
- | **/ | + | returns: |
+ | |||
+ | <code bash> | ||
+ | 24 | ||
+ | </ | ||
+ | |||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | |||
+ | * This will include the speed, and the amount of on-chip cache, processor architecture type, and the number of cores. | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Using lscpu ===== | ||
+ | |||
+ | <code bash> | ||
+ | lscpu | egrep ' | ||
+ | </ | ||
+ | |||
+ | returns: | ||
+ | |||
+ | <code bash> | ||
+ | CPU(s): | ||
+ | On-line CPU(s) list: | ||
+ | NUMA node0 CPU(s): | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Using nproc ===== | ||
+ | |||
+ | <code bash> | ||
+ | nproc | ||
+ | </ | ||
+ | |||
+ | returns: | ||
+ | |||
+ | <code bash> | ||
+ | 24 | ||
+ | </ |
ubuntu/cpu/display_the_number_of_processors.1594805433.txt.gz · Last modified: 2020/07/15 09:30 by 127.0.0.1