Only seeing 1 CPU core

You have a problem with Salix? Post here and we'll do what we can to help.
joxn
Posts: 11
Joined: 28. Oct 2020, 19:15

Only seeing 1 CPU core

Post by joxn »

I've had Salix on this slightly old ThinkPad for a while now, and whilst compiling Palemoon in Sourcery I thought I'd monitor htop, and I noticed it's only seeing one of the (2!) CPU cores. Any ideas? I've done all the obvious BIOS checks to make sure nothing is disabled, etc.

Output from cat /proc/cpuinfo

Code: Select all

processor	: 0
vendor_id	: GenuineIntel
cpu family	: 6
model		: 14
model name	: Genuine Intel(R) CPU           T2500  @ 2.00GHz
stepping	: 8
microcode	: 0x39
cpu MHz		: 1333.000
cache size	: 2048 KB
fdiv_bug	: no
f00f_bug	: no
coma_bug	: no
fpu		: yes
fpu_exception	: yes
cpuid level	: 10
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe constant_tsc arch_perfmon bts aperfmperf pni monitor vmx est tm2 xtpr pdcm dtherm
bugs		: cpu_meltdown spectre_v1 spectre_v2 l1tf mds swapgs itlb_multihit
bogomips	: 3989.95
clflush size	: 64
cache_alignment	: 64
address sizes	: 32 bits physical, 32 bits virtual
power management:
User avatar
gapan
Salix Wizard
Posts: 6238
Joined: 6. Jun 2009, 17:40

Re: Only seeing 1 CPU core

Post by gapan »

I guess that at some point you replaced the smp kernel with the non-smp one.

edit: or perhaps it is the case that you installed Salix with the non-smp kernel in the first place?
Image
Image
joxn
Posts: 11
Joined: 28. Oct 2020, 19:15

Re: Only seeing 1 CPU core

Post by joxn »

Ah so that's what smp means. I can see from my last thread that prior to following the steps at https://docs.salixos.org/wiki/How_to_in ... ent_kernel I had 4.4.19-smp (I've no idea why I ended up with that, can't remember any config during install that meant I selected it).

So now I have 4.4.240 and still only one core. What shall I do? Or is it a reinstall?
User avatar
gapan
Salix Wizard
Posts: 6238
Joined: 6. Jun 2009, 17:40

Re: Only seeing 1 CPU core

Post by gapan »

Yes, SMP means Symmetric Multiprocessing. That is, support for multiple CPUs/cores.

The answer is almost never "a reinstall". It can certainly be fixed.

Just to be certain, can you post the output of:

Code: Select all

ls /var/log/packages/kernel-*
Image
Image
joxn
Posts: 11
Joined: 28. Oct 2020, 19:15

Re: Only seeing 1 CPU core

Post by joxn »

here it is:

Code: Select all

/var/log/packages/kernel-firmware-20201005_58d41d0-noarch-1
/var/log/packages/kernel-headers-4.4.240_smp-x86-1
/var/log/packages/kernel-huge-4.4.240-i586-1
/var/log/packages/kernel-huge-smp-4.4.19_smp-i686-1_slack14.2
/var/log/packages/kernel-modules-4.4.240-i586-1
/var/log/packages/kernel-modules-smp-4.4.19_smp-i686-1_slack14.2
/var/log/packages/kernel-source-4.4.240_smp-noarch-1
User avatar
gapan
Salix Wizard
Posts: 6238
Joined: 6. Jun 2009, 17:40

Re: Only seeing 1 CPU core

Post by gapan »

OK, so you have both non-smp and smp kernels installed!

Please post the output of:

Code: Select all

ls -l /boot
I'm quite certain that there is a vmlinuz symlink pointing to the non-smp kernel. If you just point that to the smp kernel instead and run

Code: Select all

lilo -v
and reboot, you should be back to using the smp kernel.
Image
Image
joxn
Posts: 11
Joined: 28. Oct 2020, 19:15

Re: Only seeing 1 CPU core

Post by joxn »

Code: Select all

total 21076
lrwxrwxrwx 1 root root      38 Oct 28 11:51 README.initrd -> /usr/doc/mkinitrd-1.4.10/README.initrd
lrwxrwxrwx 1 root root      23 Oct 31 16:39 System.map -> System.map-huge-4.4.240
-rw-r--r-- 1 root root 3106903 Oct 21 21:18 System.map-huge-4.4.240
-rw-r--r-- 1 root root 3171959 Aug 22  2016 System.map-huge-smp-4.4.19-smp
-rw-r--r-- 1 root root     512 Oct 27 11:34 boot.0800
-rw-r--r-- 1 root root     168 Oct 27 11:34 boot_message.txt
-rw-r--r-- 1 root root     426 Aug  4  2016 coffee.dat
lrwxrwxrwx 1 root root      19 Oct 31 16:39 config -> config-huge-4.4.240
-rw-r--r-- 1 root root  162780 Oct 21 21:17 config-huge-4.4.240
-rw-r--r-- 1 root root  163217 Aug 22  2016 config-huge-smp-4.4.19-smp
-rw-r--r-- 1 root root     432 Aug  4  2016 inside.dat
-rw------- 1 root root  324096 Oct 31 16:40 map
-rw-r--r-- 1 root root     424 Aug  4  2016 onlyblue.dat
-rw-r--r-- 1 root root  307318 Aug  4  2016 salix.bmp
-rw-r--r-- 1 root root     423 Aug  4  2016 tuxlogo.dat
lrwxrwxrwx 1 root root      20 Oct 31 16:39 vmlinuz -> vmlinuz-huge-4.4.240
lrwxrwxrwx 1 root root      20 Oct 31 16:39 vmlinuz-huge -> vmlinuz-huge-4.4.240
-rw-r--r-- 1 root root 7041584 Oct 21 21:18 vmlinuz-huge-4.4.240
lrwxrwxrwx 1 root root      27 Oct 27 10:46 vmlinuz-huge-smp -> vmlinuz-huge-smp-4.4.19-smp
-rw-r--r-- 1 root root 7261936 Aug 22  2016 vmlinuz-huge-smp-4.4.19-smp
I think I understand what you are saying the problem is, but I don't know how to change a link

Would this work?

Code: Select all

ln -s /boot/vmlinuz /boot/vmlinuz-huge-smp-4.4.19-smp 
User avatar
gapan
Salix Wizard
Posts: 6238
Joined: 6. Jun 2009, 17:40

Re: Only seeing 1 CPU core

Post by gapan »

I just noticed something I missed in your previous post. The smp kernel is still 4.4.19, while the non-smp is 4.4.240.

So, run:

Code: Select all

sudo slapt-get -u
sudo slapt-get -i kernel-huge-smp kernel-modules-smp
sudo spkg -d kernel-huge kernel-modules
After that, you should see something like

Code: Select all

vmlinuz -> vmlinuz-huge-smp-4.4.240
when running

Code: Select all

ls -l /boot
Just run

Code: Select all

sudo lilo -v
if that's the case. And reboot.
Image
Image
joxn
Posts: 11
Joined: 28. Oct 2020, 19:15

Re: Only seeing 1 CPU core

Post by joxn »

That did the trick! Thank you again :)
DrCR
Posts: 58
Joined: 30. May 2014, 05:14

Re: Only seeing 1 CPU core

Post by DrCR »

@gapan,

As a side question, it appears smp/non-smp is only germane for non-AMD64 kernels?
Post Reply