Linux CPU Hotplug in VMware

Prerequisites:

  • CPU Hotplug is activated: VMware: Edit Settings -> Options -> Memory/CPU Hotplug -> CPU Hotplug
  • Note: You can only add CPU sockets. If you have configured more e.g. 4 cores per socket you can only add cores in steps of 4cpu-hotadd

Adding CPUs:

  • Raise the assigned sockets in the settings
  • Activate the added cores with the script below
cd /sys/devices/system/cpu
for i in cpu*/online
do
  if [ "`cat $i`" = "0" ]
  then
    echo 1 > $i
  fi
done

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.