Allocating Memory to Components
Distribute memory among the ATSD components using the following sizing guidelines based on available physical memory.
| Component | Memory % | Minimum, GB | Maximum, GB |
|---|---|---|---|
| ATSD Server | 20 | 1 | 8 |
| HBase | 20 | 1 | 8 |
| HDFS | 10 | 1 | 4 |
Example: 4 GB of physical memory
| Component | Heap Size, GB |
|---|---|
| ATSD Server | 1 |
| HBase | 1 |
| HDFS | 1 |
Example: 16 GB of physical memory
| Component | Heap Size, GB |
|---|---|
| ATSD Server | 3 |
| HBase | 3 |
| HDFS | 2 |
ATSD Server Heap Size
Open the ATSD server environment file.
nano /opt/atsd/atsd/conf/atsd-env.sh
Modify the -Xmx setting in the JAVA_OPTS parameter.
The format is -Xmx<size>{G|M}.
Examples:
-Xmx1024M: 1024 megabytes-Xmx2G: 2 gigabytes.
Note
No space character must be present between the number and the unit.
export JAVA_OPTS="-server -Xmx2048M -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="$atsd_home"/logs"
Restart ATSD
/opt/atsd/bin/atsd-tsd.sh stop
/opt/atsd/bin/atsd-tsd.sh start
HBase Heap Size
Open the HBase environment file and uncomment the export HBASE_HEAPSIZE line.
nano /opt/atsd/hbase/conf/hbase-env.sh
Set new maximum memory size in megabytes.
export HBASE_HEAPSIZE=4096
The setting applies to both master and region servers.
Restart ATSD and HBase:
/opt/atsd/bin/atsd-tsd.sh stop
/opt/atsd/bin/atsd-hbase.sh stop
/opt/atsd/bin/atsd-hbase.sh start
/opt/atsd/bin/atsd-tsd.sh start
HDFS Heap Size
Open the HDFS environment file and uncomment the export HADOOP_HEAPSIZE line.
nano /opt/atsd/hadoop/conf/hadoop-env.sh
Set new maximum memory size in megabytes.
export HADOOP_HEAPSIZE=4096
The setting applies to both Name and Data nodes.
Restart all services:
/opt/atsd/bin/atsd-all.sh stop
/opt/atsd/bin/atsd-all.sh start
Verify Settings
View Xmx specified in process launch arguments.
ps aux | grep Xmx
Open the ATSD portal in the top menu and verify new settings on the memory charts.

