Vyatta NOS documentation

Learn how to install, configure, and operate Vyatta Network Operating System (Vyatta NOS), which helps to drive our virtual networking and physical platforms portfolio.

Configuring CPU affinity

By default, the vRouter control and data planes share the CPUs. The data plane uses threads per CPU to perform forwarding work and additional tasks. Its optimization is automatic and high performance for average use environments. However, many environments are not average, for example:

  • Extra resources are required for controller or routing protocols.

  • Data plane threads must be reduced to avoid consuming resources.

  • Interface forwarding threads must be arranged manually for balancing the workload.

The vRouter allows you to configure CPU affinity on the default data plane. CPU affinity allows you to designate a range of CPUs used by the data plane threads.

Note: Misconfiguration of CPU affinity may adversely affect the performance of the vRouter.

If you define CPU affinity for the data plane, the data plane threads are bound to a range of CPUs and executed only on these CPUs. When the CPUs are bound to the data plane, the system and controller threads do not use these CPUs. For example, if the data plane is on an eight CPU system, and the data plane CPU affinity is set to CPUs 1 through 3, then the control and system threads use CPUs 0, and 4 through 7.

Note: The vRouter always allows control threads to run on CPU 0.

To display the number of CPUs available for the data plane, use show hardware cpu.