Separate cpu for host os from workload. Change-Id: I5b274a6324fe2fa47c09df82c01e3b95dadb5e53 Epic: PROD-8959tags/2017.4
@@ -288,6 +288,20 @@ PCI-SIG Single Root I/O Virtualization and Sharing (SR-IOV) specification define | |||
echo 7 > /sys/class/net/eth1/device/sriov_numvfs; sleep 2; ifup -a | |||
exit 0 | |||
Isolate CPU options | |||
~~~~~~~~~~~~~~~~~~~ | |||
Remove the specified CPUs, as defined by the cpu_number values, from the general kernel | |||
SMP balancing and scheduler algroithms. The only way to move a process onto or off an | |||
"isolated" CPU is via the CPU affinity syscalls. cpu_number begins at 0, so the | |||
maximum value is 1 less than the number of CPUs on the system. | |||
.. code-block:: yaml | |||
linux: | |||
system: | |||
kernel: | |||
isolcpu: 1,2,3,4,5,6,7 # isolate first cpu 0 | |||
Repositories | |||
~~~~~~~~~~~~ |
@@ -3,6 +3,21 @@ | |||
{%- if system.kernel is defined %} | |||
{%- if system.kernel.isolcpu is defined %} | |||
include: | |||
- linux.system.grub | |||
/etc/default/grub.d/90-isolcpu.cfg: | |||
file.managed: | |||
- contents: 'GRUB_CMDLINE_LINUX_DEFAULT="$GRUB_CMDLINE_LINUX_DEFAULT isolcpu={{ system.kernel.isolcpu }}"' | |||
- require: | |||
- file: grub_d_directory | |||
- watch_in: | |||
- cmd: grub_update | |||
{%- endif %} | |||
{%- if system.kernel.version is defined %} | |||
linux_kernel_package: |
@@ -20,6 +20,8 @@ linux: | |||
prompt: | |||
default: "test01.local$" | |||
kernel: | |||
sriov: True | |||
isolcpu: 1,2,3,4 | |||
hugepages: | |||
large: | |||
default: true |