How to Add Memory to AMP: A Practical Guide for Agent Memory and RAG Pipeline Builders
How to add memory to AMP trips up most builders because the phrase hides three different things: Java heap size, physical RAM, and container limits. They are not interchangeable. A forum post will tell you to bump -Xmx, a Reddit thread will tell you to cap the VM, and neither explains why your agent still crashes after you did both. Most search results are bug reports or half-answered threads, not a walkthrough.
The honest answer is that AMP has no single memory slider. You tune heap size in instance settings, you cap physical RAM at the Docker or VM layer, and you verify both. For agent memory and RAG pipeline builders, this matters more than for game servers: a misconfigured heap means dropped agent state or slower retrieval, and GigaRAG pipelines will not forgive an out-of-memory kill mid-index.
This guide covers the exact steps to set Java heap size, allocate physical RAM with Docker or VM limits, verify your settings, and know what AMP cannot do.
| At a glance | Details |
|---|---|
| What AMP is | CubeCoders game/application server manager |
| Two memory types | Java heap vs physical RAM |
| Where to set heap | Instance Configuration, Java settings |
| Hard ceiling | Cannot exceed host physical RAM |
| Docker/VM limits | Container or VM caps apply first |
| Verify with | AMP metrics and OS tools |
In This Guide
- What 'Adding Memory to AMP' Actually Means
- Java Heap Size vs Physical RAM: What Actually Limits AMP
- AMP vs. AMPS: Don't Confuse the Two
- How To Add Memory To Amp: A Step-by-Step Guide
- Prerequisites: What You Need Before Adding Memory to AMP
- Step 1: Increase Java Heap Size in AMP Instance Settings
- Step 2: Allocate Physical RAM with Docker or VM Limits
- Step 3: Verify Memory Settings and Monitor Usage
- What You Cannot Do: Honest Limitations of AMP Memory
- How to Add Memory to AMP for Agent Memory and RAG Pipelines
- Troubleshooting Common AMP Memory Issues
- Final Thoughts on Adding Memory to AMP
What 'Adding Memory to AMP' Actually Means
AMP has no single memory slider. Adding memory means changing Java heap size, physical RAM allocation, or container limits, and these are three different things.
Java heap size vs. physical RAM
Java heap size is the memory the JVM can use for objects. Physical RAM is what your host actually has. AMP's memory limit field sets heap size, not a hard RAM cap. A server with 4GB heap can still use more physical RAM for native code, threads, and garbage collection overhead.
Virtual memory in AMP: what the UI actually shows
AMP sometimes displays virtual memory instead of physical RAM. That's a known bug, not a misconfiguration. The number you see may be larger than what the process actually uses.
Why AMP does not have a single 'memory' setting
Because Java, Docker, and the host OS each enforce limits separately. You change them in different places.
[!note] AMP cannot allocate more memory than the host physically has, and it does not automatically rebalance memory across instances — each instance's heap is a setting you control. If AMP runs inside Docker or a VM, the container or VM memory limit overrides any higher Java heap value you set.
Java Heap Size vs Physical RAM: What Actually Limits AMP
| Factor | Java Heap Size | Physical RAM |
|---|---|---|
| What it is | Max memory the JVM may use for objects | Total memory installed in the host machine |
| Where set | AMP instance Java arguments (-Xmx) | Hardware, VM allocation, or container limit |
| Effect of too low | Frequent GC pauses, OutOfMemoryError | Not applicable; heap is the constraint |
| Effect of too high | Long GC pauses, host swapping | OS and other services starve for memory |
| Practical rule | Keep below host free RAM | Leave headroom for OS and AMP itself |
AMP vs. AMPS: Don't Confuse the Two
AMP and AMPS are different products from different companies. Following instructions for the wrong one wastes time.
What is AMP (CubeCoders)?
AMP is the Application Management Panel from CubeCoders. It manages game servers and application instances. This guide covers CubeCoders AMP only.
What is AMPS (60East)?
AMPS is the Advanced Message Processing System from 60East. It's a messaging platform for financial and real-time data. Nothing here applies to it.
Why search results mix them up
Both names share AMP. Search engines rank pages for both. Check the vendor before following any memory instructions.
[!tip] For agent memory and RAG pipelines hosted on AMP, set -Xms equal to -Xmx to avoid heap resizing pauses during long embedding or retrieval jobs, and leave at least a few GB of host RAM free for the OS, AMP itself, and any vector store running alongside it.
How To Add Memory To Amp: A Step-by-Step Guide
- Confirm which AMP you are using — CubeCoders AMP (game/application server manager), not AMPS (60East messaging).
- Check the host's total and free physical RAM using your OS tools or AMP's system metrics.
- If AMP runs in Docker or a VM, verify the container or VM memory limit — that cap applies before any Java setting.
- Open the instance in AMP, go to Configuration, then the Java or startup settings for that instance.
- Adjust the maximum heap (-Xmx) to a value comfortably below available physical RAM; set initial heap (-Xms) equal or lower.
- Save, restart the instance, and confirm the new heap is active via AMP metrics or the process command line.
- Monitor for OutOfMemoryError, GC pauses, or host swapping, and tune down if the host is under pressure.
Prerequisites: What You Need Before Adding Memory to AMP
Before you touch any settings, confirm three things. Skipping this means mid-tutorial frustration.
Check your host OS and available physical RAM
Know your host OS: Linux or Windows. Then check actual physical RAM. On Linux, run free -h. On Windows, open Task Manager. You cannot allocate more than the host has, so this number is your ceiling.
Determine if AMP runs in Docker, VM, or bare metal
This matters more than anything else. Docker and VM setups have their own memory limits that override AMP's internal settings. Bare metal means AMP sees the full host RAM directly. Check how you installed AMP before proceeding.
Back up your AMP instance configuration
Copy your instance's configuration files before changing memory settings. A bad Java argument can stop an instance from starting. The backup takes seconds and saves a reinstall.
Step 1: Increase Java Heap Size in AMP Instance Settings
The most direct way to add memory for Java-based servers in AMP is to change the JVM heap size. This setting controls how much RAM Java can use for objects, and it's the first thing to adjust for Minecraft, Valheim, or any other Java application.
Locate the instance settings in AMP
Open the AMP web panel and select the instance you want to modify. Click Configuration, then Java and Memory Settings. The exact label varies by AMP version, but it's always under the instance's configuration section, not the global AMP settings.
Set -Xms and -Xmx values
You'll see two fields: initial heap size and maximum heap size. These map to the JVM arguments -Xms and -Xmx. Set -Xms to the amount of RAM Java starts with, and -Xmx to the ceiling it can grow to. A common starting point is -Xms 1G -Xmx 4G for a small Minecraft server. Don't set them equal unless you have a specific reason; letting the heap grow as needed reduces startup overhead.
Example configurations for different server types
For a vanilla Minecraft server with 2-4 players, -Xms 1G -Xmx 2G works. For a modded Minecraft pack, start at -Xms 2G -Xmx 6G. For a Valheim server (which runs on .NET, not Java), these settings do nothing; skip to Docker or VM limits instead. After changing the values, restart the instance. The new heap size takes effect on the next launch.
Step 2: Allocate Physical RAM with Docker or VM Limits
Java heap size only caps what the JVM uses for objects. The JVM itself, native libraries, and any non-Java processes running alongside it all consume additional RAM. A 4G heap can easily translate to 6G or more of total usage.
Why Java heap size is not a hard RAM cap
The -Xmx flag limits heap, not total memory. Metaspace, thread stacks, code cache, and off-heap buffers all sit outside it. If your host has 8G physical RAM and you set -Xmx 6G, the instance can still exhaust the machine.
Setting Docker memory limits for AMP
If AMP runs in Docker, add --memory=6g to the container's run command or set mem_limit: 6g in docker-compose. This is a hard ceiling: the container gets killed if it exceeds it. Set it below your host's total RAM.
Setting VM memory limits for AMP
For AMP in a VM, configure the memory allocation in your hypervisor (VirtualBox, Proxmox, ESXi). The VM sees that as its physical RAM. Leave headroom for the host OS.
Step 3: Verify Memory Settings and Monitor Usage
You changed the settings. Now confirm they took effect. AMP's UI shows one number; your OS shows another. They won't always match.
Check AMP's memory display
Open the instance console in AMP and look at the memory readout. If it shows virtual memory instead of physical RAM, that's a known display bug, not your configuration failing. Trust the OS tools for actual usage.
Use OS tools to verify actual RAM usage
On Linux, run top or htop and check the RES column. On Windows, Task Manager's memory column shows working set. Compare that against the limit you set in Step 2.
Common verification pitfalls
Don't check immediately after restart. Wait for the instance to load fully. And don't trust AMP's displayed memory if it disagrees with top. The OS is right.
What You Cannot Do: Honest Limitations of AMP Memory
AMP gives you control, but that control has hard edges. You can't bend physics.
You cannot allocate more RAM than your host has
If your machine has 16GB, you can't give an instance 32GB. AMP will accept the setting, but the JVM will crash on startup or swap to disk and crawl. Check your host's physical RAM before touching any slider.
AMP does not automatically manage memory across instances
AMP won't balance load. If you run three instances and one needs more RAM, nothing reallocates from the others. You set limits per instance, and that's it. Overcommitment is your problem, not AMP's.
Non-Java applications need different memory settings
AMP hosts plenty of non-Java servers: Valheim, Rust, ARK. The -Xmx and -Xms flags do nothing for those. You're back to Docker limits or OS-level controls. Don't expect one memory setting to rule them all.
How to Add Memory to AMP for Agent Memory and RAG Pipelines
Agent memory and RAG pipelines punish unpredictable memory. A heap that resizes mid-query adds latency. A container that gets OOM-killed loses agent state. You need stable allocation, not just more RAM.
Why agent memory needs predictable heap size
Set -Xms equal to -Xmx. That tells the JVM to allocate the full heap upfront and never resize. For a Java-based agent holding conversation state or vector indexes, resizing means garbage collection pauses mid-retrieval. Predictable heap size removes that variable.
Docker limits for RAG pipeline services
RAG services often run as containers under AMP. Use Docker's --memory flag to cap total RAM, not just heap. A vector database plus an embedding model plus your agent can exceed heap limits fast. The container limit is the real ceiling.
Example: GigaRAG with properly configured AMP memory
GigaRAG, a RAG pipeline tool, benefits directly from this setup. Give it a fixed heap and a Docker memory cap, and retrieval latency stays flat under load. Misconfigure it, and you'll see timeouts that look like code bugs but are actually memory pressure.
Troubleshooting Common AMP Memory Issues
Most AMP memory problems come down to three things: the UI showing the wrong number, the heap being too small for the workload, or settings not sticking after a restart. Here's how to fix each.
AMP shows virtual memory instead of physical RAM
AMP sometimes reports virtual memory (VSZ) rather than resident memory (RSS). Virtual memory includes swapped pages and mapped files, so it can look far larger than what the process actually uses. Don't trust that number. Check top or Task Manager for the real RSS value.
Out-of-memory crashes despite high heap size
A high -Xmx doesn't cap total memory. The JVM uses heap plus metaspace, thread stacks, and native buffers. If the container or host runs out of physical RAM, the OS kills the process. Lower -Xmx or raise the Docker/VM limit.
Settings not applying after restart
AMP caches instance configs. After changing Java arguments, stop the instance fully, wait five seconds, then start it again. A quick restart sometimes skips the config reload.
Final Thoughts on Adding Memory to AMP
Adding memory to AMP comes down to three moves: set the Java heap with -Xms and -Xmx, cap total usage with Docker or VM limits, then verify with OS tools. Skip any one of them and you'll chase phantom crashes.
The honest answer is that AMP gives you control, not magic. It won't stop you from overcommitting RAM, and it won't balance memory across instances. You set the numbers. The host enforces them.
For agent memory and RAG pipeline builders, predictable memory means predictable retrieval latency. If you're running GigaRAG or similar services under AMP, apply the same discipline: fixed heap for Java components, hard container limits for everything else. Get that right and memory stops being the thing you debug at 2 a.m.
Frequently Asked Questions
Is 10GB RAM too much for Minecraft?
For vanilla Minecraft, 10GB is more than most servers need and can actually increase garbage collection pauses. For heavily modded packs or many concurrent players, 10GB can be reasonable. The right value depends on your mod count, player count, and view distance — start lower and increase only if you see memory pressure.
How do I increase my RAM size?
You cannot increase physical RAM through software; you either install more memory in the host or raise the Java heap ceiling within the RAM you already have. In AMP, that means editing the instance's Java arguments (-Xmx) after confirming the host and any container limits allow it.
How to update an AMP server?
Use the AMP panel's built-in update mechanism for the instance or the controller, depending on your setup. Back up instance data first, then apply updates during a maintenance window. Exact steps vary by AMP version, so check the current CubeCoders documentation for your release.
Is 32GB RAM enough for Minecraft?
32GB is plenty for most Minecraft servers, including large modded packs, as long as you do not assign all of it to a single JVM heap. Leave several GB for the OS, AMP, and other services. Assigning the entire 32GB to one instance usually hurts performance rather than helping.
How do I add more RAM to a modded Minecraft server?
In AMP, open the instance configuration and raise the maximum heap size (-Xmx) in the Java settings, keeping it below the host's free physical RAM. Modded packs often need more heap than vanilla, but going too high causes long GC pauses. Test incrementally and watch AMP's memory metrics.
Why does my AMP instance still run out of memory after I increased the heap?
Common causes include a Docker or VM memory limit capping the container below your heap setting, the host itself being low on free RAM, or a memory leak in the application. Check container limits first, then host free memory, then application-level leaks.
About GigaRAG
GigaRAG is for agent memory and RAG pipeline builders. get this right. Whether you are working through How to add memory to Amp or something adjacent, we publish what we have actually tested, including where it falls short.


