User Tools

Site Tools


nfv-kvm-test

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
nfv-kvm-test [2015/11/24 01:00]
Liang Li
nfv-kvm-test [2016/01/04 06:24]
Chao Peng
Line 122: Line 122:
  
 </​code>​ </​code>​
-===== Host Environment Setup =====+===== Software ​Environment Setup =====
 We need setup both the host/guest environment,​ to reduce any noise. https://​gerrit.opnfv.org/​gerrit/#/​c/​2161/​ gives detailed implementation on how to setup the environment setup. Below are descriptions of the work done there. We need setup both the host/guest environment,​ to reduce any noise. https://​gerrit.opnfv.org/​gerrit/#/​c/​2161/​ gives detailed implementation on how to setup the environment setup. Below are descriptions of the work done there.
  
 ==== Kernel Parameter ==== ==== Kernel Parameter ====
-Several kernel parameters are important to achieve real performance for the VNF. 
  
-1. Setup the isolated CPUs +__Kernel configuration__: ​kernel/arch/x86/configs/opnfv.config.
-Isolated CPUs make sure the kernel ​will not schedule process to the specified isolated CPUs unless requested explicitly. Please refer to http://lxr.free-electrons.com/source/Documentation/​kernel-parameters.txt#​L1608 for more informationNormally, the physical CPUs planned to host the VNF should be marked as isolated CPUs.+
  
-2. Setup the NOHZ_FULL +__Host kernel boot line example__: isolcpus=11-15,31-35 nohz_full=11-15,31-35 rcu_nocbs=11-15,31-35 iommu=pt intel_iommu=on default_hugepagesz=1G hugepagesz=1G mce=off idle=poll intel_pstate=disable processor.max_cstate=1 pcie_asmp=off tsc=reliable
-NOHZ_FULL is meaningful to reduce the jitter caused by host to the VNF. With NOHZ_FULLthe physical CPU will trigger much less tick timer interrupt (currently1 tick per second). This will reduce the impact to the VNFbecause each host timer interrupt will trigger VM exit from guest to host and cause performance/​latency impact+
  
-3. Setup the RCU_NOCB +__Guest ​kernel ​boot line example__ ​isolcpus=1 nohz_full=1 rcu_nocbs=1 mce=off idle=poll default_hugepagesz=1G hugepagesz=1G ​
-RCU is a kernel ​synchronization mechanism. Refer to http://​lxr.free-electrons.com/​source/​Documentation/​RCU/​whatisRCU.txt for more information. With RCU_NOCB, the impact from RCU to the VNF will be reduced a lot.+
  
-4. Mark the tsc as reliable +Please ​refer to [[nfv-kvm-tuning]] for more explanation.
-Please ​notice that this is a little bit hacky while we are providing a cleaner solution. A TSC clock source that is thought as unreliable will cause kernel ​to continuous to enable clock source watchdog to check if TSC frequency is still correct. On latest Intel platform with Constant TSC/​Invariant TSC/​Synchronized TSC, the TSC is reliable already. We are on the process to submit a patch to the kernel.+
  
 ==== Run-time Environment Setup ==== ==== Run-time Environment Setup ====
 Not only special kernel parameter needed, also run-time environment adjustment is needed. Below are some BKMs. Not only special kernel parameter needed, also run-time environment adjustment is needed. Below are some BKMs.
  
-1.Disable the RT throttling +Please refer to [[nfv-kvm-tuning]] for more explanation.
-As the VNF's vCPU thread runs continuous on the guest environment,​ we need disable the RT throttling ​to avoid performance impact to the vCPU thread.+
  
-2. Interrupt binding 
-We should make sure no interrupt will be routed to the isolated CPU, on which the vCPU thread are executed. 
 ====== Test Description ====== ====== Test Description ======
  
nfv-kvm-test.txt · Last modified: 2016/01/04 06:24 by Chao Peng