Eu tenho testado essas coisas tentando reservar algumas CPUs em um host com dois processadores Intel E5645, mas não consigo fazê-lo funcionar por algum motivo. Etapas que segui:
-
Edite / etc / default / grub e adicione isolcpus = 0,1 a GRUB_CMDLINE_LINUX_DEFAULT
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash isolcpus=0,1"
-
Execute update-grub
- Reinicializar
Depois disso, cat / proc / cmdline revela:
BOOT_IMAGE=/boot/vmlinuz-3.2.0-26-generic root=UUID=52cfedad-40be-41b9-9f88-c282a7ae3f24 ro quiet splash isolcpus=0,1 vt.handoff=7
Testado usando estresse:
apt-get install stress && stress -c 24
Monitorado usando a parte superior e pressionando 1 para exibir estatísticas individuais da CPU. Até o momento, nenhuma CPU está isolada do escalonador e todas estão presas de estresse.
Cpu0 : 99.7%us, 0.3%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu1 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu2 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu3 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu4 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu5 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu6 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu7 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu8 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu9 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu10 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu11 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu12 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu13 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu14 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu15 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu16 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu17 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu18 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu19 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu20 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu21 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu22 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Cpu23 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa
Testado o mesmo material no CentOS 6 x86_64 e funciona como esperado.
Pesquisou o banco de dados do Ubuntu e do Linux no launchpad, mas não encontrou nada até agora.
Sou eu burro ou sinto falta de alguma coisa? Dicas?
Obrigado!
Refs:
link