Bash/CPU
# show no.of core of a cpu
grep '^core id' /proc/cpuinfo |sort -u|wc -l
# show no.of threads of a cpu
grep -c ^processor /proc/cpuinfo
getconf _NPROCESSORS_ONLN
nproc --all
# show no.of core of a cpu
grep '^core id' /proc/cpuinfo |sort -u|wc -l
# show no.of threads of a cpu
grep -c ^processor /proc/cpuinfo
getconf _NPROCESSORS_ONLN
nproc --all