Skip to content

Commit 437d71c

Browse files
authored
Update vm.max_map_count info (#1417)
* vm.max_map_count info * remove unnecessary words * PR changes
1 parent 10f77e6 commit 437d71c

File tree

2 files changed

+27
-0
lines changed

2 files changed

+27
-0
lines changed

pages/database-management/system-configuration.mdx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,11 @@ For optimal system performance, the `vm.max_map_count` value should be chosen in
5656
accordance with your system's RAM, aiming for approximately one memory map area
5757
per 128 KB of system memory.
5858

59+
<Callout type="warning">
60+
The recommended values below are starting points and may need to be increased depending on your workload.
61+
If you encounter `munmap` errors or crashes due to `bad_alloc` errors, you should try increasing the `vm.max_map_count` value beyond the recommended amount.
62+
</Callout>
63+
5964
| Amount of RAM | `vm.max_map_count` value |
6065
|---------------|-------------------------|
6166
| 8GB - 32GB | `vm.max_map_count=262144`|

pages/deployment/workloads/memgraph-in-high-throughput-workloads.mdx

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,9 @@ The suggestions for high-throughput workloads **complement** several key section
7474
[general suggestions guide](/memgraph-in-production/general-suggestions). These sections offer important context and
7575
additional best practices tailored for performance, stability, and scalability in high-throughput systems:
7676

77+
- [Hardware configuration](#hardware-configuration) <br />
78+
Critical system settings for high-throughput workloads, including `vm.max_map_count` configuration.
79+
7780
- [Choosing the right Memgraph flag set](#choosing-the-right-memgraph-flag-set) <br />
7881
Memgraph offers specific flags to optimize streaming graph updates.
7982

@@ -90,6 +93,25 @@ additional best practices tailored for performance, stability, and scalability i
9093
- [Queries that best suit your workload](#queries-that-best-suit-your-workload)
9194
Learn how to optimize update queries coming at the database.
9295

96+
## Hardware configuration
97+
98+
High-throughput workloads place significant demands on system resources, making proper hardware configuration essential for stable and performant operations.
99+
100+
One of the most critical system settings for high-throughput workloads is configuring the kernel parameter `vm.max_map_count`.
101+
This setting ensures that the system can allocate enough virtual memory areas, which is essential for avoiding memory-related issues.
102+
103+
<Callout type="warning">
104+
The standard recommended values for `vm.max_map_count` may be insufficient for high-throughput operations.
105+
If you encounter `munmap` errors or crashes due to `bad_alloc` errors, you should try increasing the `vm.max_map_count` value beyond the recommended amount.
106+
</Callout>
107+
108+
You can find detailed setup instructions and recommended values in our
109+
[system configuration documentation](/database-management/system-configuration#recommended-values-for-the-vmmax_map_count-parameter).
110+
111+
If you're deploying Memgraph on Kubernetes, our Helm charts include an **init container** that automatically sets `vm.max_map_count`
112+
during startup. However, this container requires **root privileges** to execute. If you're running in a restricted environment
113+
or prefer not to use privileged containers, you'll need to **manually configure** this parameter on the host machine.
114+
93115
## Choosing the right Memgraph flag set
94116

95117
When streaming data from systems like Kafka, the incoming payload is often **standardized**,

0 commit comments

Comments
 (0)