Close

SAP Performance Analysis with Tcode ST02

3. SAP ST02 transaction and memory analysis

3.1. SAP Buffer analysis
SAP Buffer analysis is to focus on following items

  • Hit rate: should not be lower than 98% except program buffer, single record buffer and export/import buffer where low hit rate is normally considered acceptable.
  • Swaps: The goal is to avoid swap in all Buffer except program buffer. Low swaps in single record buffer and export/import buffer is not significant.
  • Enough Free memory and free directory entry: this would help avoid swap. If there is free space but there is no free directory, this would cause swap. Vice Versa.

If you saw big swaps, less free directory and/or less free memory space, it would reduce swap to increase configured memory space and/or max directory entry when free main memory is available.

SWAP and buffer invalidation is different concept. Buffer invalidation is due to changes on buffered object which would involve transfer from database table. SWAP is due to shortage of free buffer space/directory. Buffer invalidation is not reflected in swap column but it would increase “database access”. SWAP itself would not increase “database access”. But next read on a swap buffered object would trigger system’s action to reload the swapped object from database, this would increase “database access”.

If database access is high for table space buffer area and swap is low, you might need to review table buffering for the instance, this could be due to a frequent changed buffered table whose buffering should be turned off. You can use SAP transaction ST10 to review table buffering or you can navigate to table buffering from the main screen.

3.2. SAP Memory analysis

3.2.1. SAP Memory analysis instance level
SAP extended memory, Heap memory, Roll memory and Page memory are SAP memory space shared by all SAP work processes. SAP memory analysis is to focus on following items

  • Free memory: We should have enough free memory in Extended and Heap memory. Current used memory should not exceed 80% to ensure that free memory is still available for new memory demand.
  • Maximum memory: Maximum used memory since start of instance should be lower than 80% of what configured memory for Extended memory and Heap memory. Otherwise, there might be memory contention causing job/program cancellation. For SAP page memory and Roll memory, the maximum used memory should not exceed sum of amount configured “in Memory” column and on disk.

It is important to online transaction performance to have enough extended memory. If this is no free extended memory, SAP work process would get memory from heap area based on SAP allocation sequence for dialog tasks. Once a Dialog is using heap memory, the SAP dialog process would be in a Private mode – cannot be shared with other tasks. If many dialog processes are put into “private mode”, this would impact dialog response time and RFC task due to shortage of dialog work processes.

If current usage is high for extended memory/heap memory space, you can go to mode list screen (Figure 3 screen) to find which program and users are consuming those memory. Base on those information, you can decide whether we need to tune memory usage for the programs and jobs, reschedule the jobs/programs or we need to have more extended memory.

3.2.2. SAP Memory analysis at individual job/user level
Figure 2 screen also shows type and amount of memory which can be used by a single SAP work process and which one should be used first (Allocation sequence). The actual memory allocation for a SAP work process would depend on memory demand of the program and availability of memory of each type. A SAP work process would be terminated by SAP system if there is no memory at last step of allocation. Based on figure 2, Dialog task can have up to 7M memory in the extended memory space, if an online SAP process needs less than 7M bytes memory and there is at least 7M bytes free memory from Extended Memory, it would not use “Roll” and “heap” memory. If the online process needs more memory than what is available in heap memory after it consumes available memory from extended and roll memory space, the program/process would be terminated by system due to memory resource contention issue. In similar way, a SAP background job/process would be terminated by SAP system if the job needs more memory than what is available at extended memory space due to the fact that the job needs more than what allowed by the quota or running out of extended memory.

 

scroll to top