NUMA Control and CPU Affinity
Non-Uniform Memory Access (NUMA) is to be used with machines that have multiple physical CPUs.
The performance of accessing RAM from a CPU depends on whether the RAM is physically attached to the same CPU or to another CPU. Therefore, application performance can be enhanced by constraining the application to stay within a single physical CPU. A Linux command, numactl, supports this control. For more information, use man numactl.
- If a job with NUMA control requested is executed on a machine with a single socket, NUMA will be ineffective, but no problems will occur.
- NUMA is supported only on Linux machines.
Placement Types
- Pack: the placement selects CPUs in a way that minimizes the number of unused cores in each CPU.
- Spread: the placement selects CPUs in a way that minimizes the loading of each CPU.
Examples of Job Submission with NUMA
% nc run -r CORES/2 -jpp pack -- my_job
% nc run -r CORES/4 -jpp spread -- my_job
To monitor the effect of CPU affinity, check the job property named "NUMA_AFFINITY":
% nc list -O "@ID@ @PROP.NUMA_AFFINITY@ @STATUSNC@"
283569646 NUMA pack: 0 * * * * * * * * * * * * * * * Running
283569650 NUMA pack: * 1 2 * * * * * * * * * * * * * Running
283569654 NUMA pack: * * * * 4 5 6 7 * * * * 12 13 * * Running
283569658 NUMA spread: * * * * * * * * * * * * * * 14 * Running
283569662 NUMA spread: * * * * * * * * * * * * * * * 15 Running
283569665 NUMA spread: * * * 3 * * * * * * * * * * * * Running
Check Tasker NUMA Status
% nc cmd vovselect prop.NUMA_LAYOUT from taskers where name==foo
Original: Used/Total _________+__
Socket: 0 RAM= 512/32089 ****oooooooo
Socket: 1 RAM= 1024/32089 ********oooo