How to Configure NUMA-Aware Memory Allocation
Enable NUMA-aware memory allocation in GridGain 8 so data regions optimize memory access patterns on multiprocessor Linux hardware for higher performance.
Prerequisites
A Linux system, such as amd64 Linux (NUMA only works on Linux).
Hardware that supports NUMA. If it does not, NUMA-aware memory allocation will not improve performance.
Overview
This guide explains how to leverage the NUMA-aware memory allocation within the GridGain Unified Real-Time Data Platform. NUMA stands for "Non-Uniform Memory Access." It is a computer memory design used in multiprocessors, where the memory access time depends on the memory location relative to the processor. Using NUMA-aware allocation, applications running on GridGain can achieve higher performance as they optimize memory access patterns. Specific performance benefits depend on your environment, application load, and system resources.
Step 1: Install the Required Packages
Make sure that your Linux system has libnuma and numactl installed. These packages are necessary for managing and configuring NUMA on your system. Use your system's package manager to install them:
sudo apt-get update
sudo apt-get install libnuma-dev numactlsudo yum install numactl libnuma-develStep 2: Configure NUMA Nodes
While libnuma comes with a default configuration that works seamlessly with GridGain, you may need to tailor the NUMA nodes to your specific requirements for optimal performance. Use numactl to modify the configuration.
To view your system's NUMA configuration:
numactl --hardwareTo set a specific NUMA policy for an application, use
numactlwith the relevant options. For example, to bind a process to a specific node:numactl --cpunodebind=0 --membind=0 your_commandAdjust node numbers based on your hardware configuration and requirements.
Step 3: Enable the NUMA Allocator in GridGain
Enable the ignite-numa-allocator module that enables GridGain data regions to allocate memory using NUMA:
Navigate to your GridGain installation directory.
Move the
ignite-numa-allocatormodule from thelibs/optionaldirectory tolibs.
Step 4: Configure NUMA for Data Regions
To enable NUMA-aware allocation for a specific data region, adjust the memoryAllocator property in that region's DataRegionConfiguration in the GridGain configuration file (e.g., ignite.xml):
Open your GridGain configuration file in a text editor.
Locate the
DataRegionConfigurationsection.Set the
memoryAllocatorproperty to one of the NUMA allocation strategies (see strategy descriptions below).
Simple Allocation Strategy
This strategy is the best for attaching a data region to a specific NUMA node.
On all NUMA Nodes
On a Specific Node
Interleaved Allocation Strategy
This strategy is optimal for distributing a data region across multiple NUMA nodes.
On all NUMA Nodes
On Specified NUMA Nodes
Local Node Allocation Strategy
This strategy is used for allocating on the local NUMA node of the process.
Step 5: Enable NUMA-Aware Allocation in the JVM
To ensure the JVM itself is optimized for NUMA, use the -XX:+UseNUMA JVM option by setting the JVM_OPTS environment variable:
Step 6: Start a GridGain Node and Load Data
Start your GridGain node with the modified configuration:
Using either a thick or a thin client, put some data into the data region you have configured for NUMA allocation to trigger the allocation.
Step 7: Verify NUMA Allocation
To confirm that NUMA allocation is functioning correctly, inspect the numa_maps file for the GridGain node's process:
Find your GridGain node's process ID (PID).
Check the
numa_mapsfile:
A non-empty list of pages allocated with NUMA means that your data region is now utilizing NUMA-aware memory allocation, which should enhance the performance of your GridGain deployments on NUMA-enabled systems.
Related
Non-Uniform Memory Access (NUMA) - Background on the memory design this guide optimizes for.
HotSpot (virtual machine) - The Java implementation required for
-XX:+UseNUMA.
This page is: Copyright © 2026 MariaDB. All rights reserved.
Last updated
Was this helpful?

