last updated: 2024-05-01
Introduction
SAP HANA is an in-memory database architecture. This architecture is the heart of the concept. Huge knowledge available about SAP HANA memory topic, but the knowledge is fragmented (Help Portal, Blog post, SAP KBA, SAP Note, other). In order to simply and make content consumption easier I have created a centralized page, a single source of the available information regarding SAP HANA memory.
What is SAP HANA?
Table of Content (The internal links had been removed cause the new blogging platform only supports basic html, and the use of anchor links not supported.)
- Where to find documentations in SAP Help Portal?
- Which is the master SAP Knowledge Base Article of the SAP HANA memory?
- Concept of the SAP HANA memory structure
- Which memory measurement values needs to be understand?
- What does resident means?
- How to limit SAP HANA memory consumption?
- What is the general way to monitoring the SAP HANA memory usage?
- What are the available tools for monitoring the SAP HANA memory usage?
- Which SAP HANA Alert IDs belongs to the topic?
- What is the recommended way of troubleshooting the SAP HANA memory usage?
- What else is recommended to check in case of memory issue?
- Which other documentation is important regarding SAP HANA memory?
- What blog posts can be helpful?
- Other articles in this series
- Other articles in connected series
- Useful bookmark
IMPORTANT !
=================================================================
Where to find documentations in SAP Help Portal?
Which is the master SAP Knowledge Base Article of the SAP HANA memory?
=================================================================
Concept of the SAP HANA memory structure
This is essential to understand the memory concept of the SAP HANA database system. The most used illustration explains how the memory structure looks like and which important areas are exists.
Image source: SAP Knowledge Base Article - 1999997 - FAQ: SAP HANA Memory
❗Rule of thumb: the recommendation from SAP is the tables data should not use more than 50 % of the available memory.
- 1999997 - FAQ: SAP HANA Memory
➡️45. What is a good table memory share?
➡️10. How can I judge if the available memory is sufficient for the current system and a projected future growth?
Which memory measurement values needs to be understand?
Below graph shows different memory measurement values on a time scale.
Image source: HA200 - SAP HANA 2.0 SPS05 - Installation and Administration
Basic understanding and high level quick overview, about SAP HANA memory topic explained in the following Learning Journeys in SAP Learning site (Installing and Administering SAP HANA - - > Unit 7 (Monitoring using SAP HANA Cockpit) - - > Checking the Memory Usage).
Overview of these memory usage indicators can be checked in SAP HANA Studio and in SAP HANA Cockpit.
Removed content (video): SAP Product Support: SAP HANA Memory Management - SAP HANA Academy [2.0 SPS 01]
Reason: As the SAP HANA Academy youtube channel had been discontinued.
SYSTEMDB:
HXE (Tenant DB):
❗Note: While we are checking the values, only the
'Database Resident' numbers are different. This number belongs to the actual database while other numbers are belongs to the overall system.
What does resident means?SAP HANA database is
greedy. It means the database reserves its memory even if it is not used. SAP HANA does not care if some amount memory actually not used by the database. It assumes if memory assigned (GAL) to the database and it was used before, it will be used in the "near" future, so the database does not release the memory.
Also a Former Member has a nice explanation about the topic:
The related SAP HANA documentations:- 2081473 - SAP HANA Resident Memory: High Memory Usage
- 3134933 - HANA database Resident memory is different from OS command "free -h"
- 2743981 - Resident Memory and Used Memory for MDC system in HANA Studio Overview
- 3265791 - EWA report, "Almost all available physical memory of the SAP HANA server was in use"
How to limit SAP HANA memory consumption?- 3202692 - How to set Memory Limit for SQL Statements
- 2383578 - How to set HANA memory limit for a single user
- 2926166 - How to limit the overall SAP HANA memory allocation
- 2175606 - HANA: How to set allocation limit for tenant databases
- 2924720 - Is it possible to Limit maximum memory allocation of SYSTEMDB?
What is the general way to monitoring the SAP HANA memory usage?- 3058134 - Monitoring SAP HANA Memory usage statistics
What are the available tools for monitoring the SAP HANA memory usage?The general way to do the monitoring is to use SQL commands. The actual memory information can be reviewed with the following SQL Statement:
“HANA_Memory_Overview”.
- 1969700 - SQL Statement Collection for SAP HANA
- 3330262 - SQL Statement Collection: "HANA_Memory_Overview" report for SAP HANA
The action can be done in a graphical way also.