941735
TRANSCRIPT
![Page 1: 941735](https://reader037.vdocuments.pub/reader037/viewer/2022100218/577d1da71a28ab4e1e8cab5f/html5/thumbnails/1.jpg)
7/31/2019 941735
http://slidepdf.com/reader/full/941735 1/5
19.01.2008 Page 1 of 5
Note 941735 - SAP memory management for 64-bit Linux systems
Note Language: English Version: 5 Validity: Valid from 31.01.2007
Summary
SymptomRecommendation for parameterization of 64-bit Linux systems.
More TermsLinux memory management, es/implementation, STD, MAP, TMPFS, /dev/shm,
64-bit, em/initial_size_MB
Cause and PrerequisitesFor SAP on Linux, two different memory management systems are available.
You can switch between the two systems using the SAP instance profile
parameter es/implementation:
o MAP implementation (es/implementation=map)
This variant is mainly used for 32-bit systems, and is described in
detail in Note 386605.
As of SAP kernel 6.20, an SAP system on Linux uses the MAP
implementation by default, in which only the currently active user
context is displayed in the address space of the work process.
o STD implementation (es/implementation=std)
With this variant, the memory management of an SAP system on Linuxis the same as on standard UNIX systems. This means that all user
contexts are displayed in the address space at the same time, which
means that this variant is only available for 64 bit systems.
While the MAP implementation should be used exclusively on 32-bit Linux in
more cases, both variants can be used on 64-bit systems. However, since
there are no longer any 32-bit restrictions, there is no longer any need to
use the special MAP implementation on 64-bit Linux systems .
For this reason, the STD implementation for SAP systems on64-bit Linux is activated by default as of SAP Kernel 7.10.
SolutionIf you want to use the STD implementation with older SAP kernels, you can
activate it using the profile parameter es/implementation=std.
Relevant parameters for the STD implementation
A) SAP profile parameters
o em/initial_size_MB
This parameter specifies how much Extended Memory is available to
the SAP system.
![Page 2: 941735](https://reader037.vdocuments.pub/reader037/viewer/2022100218/577d1da71a28ab4e1e8cab5f/html5/thumbnails/2.jpg)
7/31/2019 941735
http://slidepdf.com/reader/full/941735 2/5
19.01.2008 Page 2 of 5
Note 941735 - SAP memory management for 64-bit Linux systems
In the SAP Extended Memory, there are additional SAP internal
memory areas, which cannot be directly accessed by the user
contexts. These include the areas that are configured using the
parameters em/global_area_MB and abap/shared_objects_size_MB. Note:
For the user contexts in the system, only the difference of
em/initial_size_MB - (em/global_area_MB +
abap/shared_objects_size_MB)
can be used as Extended Memory.
o ztta/roll_extension
This parameter specifies how much SAP Extended Memory is available
to an individual user context.
This quota can be set differently for dialog and background work
processes if necessary. To do this, use the parametersztta/roll_extension_dia for dialog work processes or
ztta/roll_extension_nondia for background work processes.
The three profile parameters used with the MAP implementation
(em/address_space_MB, em/max_size_MB and PHYS_MEMSIZE) are notrelevant if you use the STD implementation.
B) Linux operating system parametersThe following Linux kernel parameters can be configured using the sysctl
interface. To do this, you must edit the file /etc/sysctl.conf accordingly:
o kernel.shmmax
This kernel parameter specifies how large an individual SysV Shared
Memory Segment is allowed to be. In the case of an STD
implementation, the parameter must be set sufficiently large in
order to allow em/initial_size_MB. The value is specified in the
unit Bytes so that "21474836480", for example, permits segments of
20 GB.
o kernel.shmall
This kernel parameter specifies how much SysV Shared Memory is
available in the Linux system as a whole. As an estimate for therequirements of the SAP system, you can use the total of the SAP
Extended Memory (em/initial_size_MB) + SAP buffer (transaction ST02
-> Detail analysis menu -> Storage, row with the entry "Total").
If several SAP systems are running on a Linux server, the
requirements increase accordingly. The same applies for databases
that may be operating on the same Linux server.
As a configuration recommendation, kernel.shmall can be configured
as the amount of virtual memory in the Linux system (RAM + Swap).
The value is specified in the unit "4 KB blocks", so that"5242880", for example, permits 20 GB SysV Shared Memory in the
Linux system as a whole.
![Page 3: 941735](https://reader037.vdocuments.pub/reader037/viewer/2022100218/577d1da71a28ab4e1e8cab5f/html5/thumbnails/3.jpg)
7/31/2019 941735
http://slidepdf.com/reader/full/941735 3/5
19.01.2008 Page 3 of 5
Note 941735 - SAP memory management for 64-bit Linux systems
o TMPFS
With the STD implementation, the SAP Extended Memory is no longer
stored in the TMPFS (under /dev/shm). However, the TMPFS is
required by the Virtual Machine Container (VMC). For this reason,
we still recommend the same configuration of the TMPFS:
75% (RAM + Swap) is still recommended as the size.
Points to remember when using the STD implementation
o Background work processes now use memory close to the process
(heap) as the first large memory type. The allocation sequence for
"NonDia" work processes is as follows:
1. Roll memory (ztta/roll_first),
2. Heap memory (abap/heap_area_nondia),
3. Roll memory (ztta/roll_area - ztta/roll_first),
4. Extended Memory (ztta/roll_extension(_nondia)).
In the case of dialog work processes, the allocation sequence
remains unchanged from that used in the MAP implementation:
1. Roll memory (ztta/roll_first),
2. Extended Memory (ztta/roll_extension(_dia)),
3. Roll memory (ztta/roll_area - ztta/roll_first),
4. Heap memory (abap/heap_area_dia).
The allocation sequence can be changed using the RSMEMORY report.
o In transaction ST02, the "In Memory" display for the "Extended
Memory" entry shows the SAP Extended Memory available for the SAP
instance. The value of the parameter em/initial_size_MB is used as
a basic value. However, the Extended Memory is not automatically
increased to the value of em/max_size_MB with the STD
implementation.
Frequent problems in connection with the STD implementationThe following problems or error messages may occur when you carry out the
STD implementation:
o ERROR shmget() (28: No space left on device)
Example from dev_w0:
...
M SHM_ROLL_ADM (addr: 0x2a99dc7000, size: 2672386)
M SHM_PAGING_ADM (addr: 0x2bb1ae6000, size: 656416)I *** ERROR => shmget(13040,112000000,2016) (28: No space left on
device) [shmux.c 1407]
![Page 4: 941735](https://reader037.vdocuments.pub/reader037/viewer/2022100218/577d1da71a28ab4e1e8cab5f/html5/thumbnails/4.jpg)
7/31/2019 941735
http://slidepdf.com/reader/full/941735 4/5
19.01.2008 Page 4 of 5
Note 941735 - SAP memory management for 64-bit Linux systems
I *** ERROR => shmget(13040,112000000,992) (28: No space left on
device) [shmux.c 1407]
I *** ERROR => Shm Pool Create Error. PoolKey=40, Key=48. [shmux.c
1892]
...
Example from dev_disp:
...
EmInit: MmSetImplementation( 2 ).
MM global diagnostic options set: 0
client 0 initializing ....
InitFreeList
block size is 4096 kByte.
Using implementation std
EsStdUnamFileMapInit: shmget() of 10737418240 bytes failed.
errno = 28(No space left on device)
EsStdInit: unable to allocate 10240 MB
EsStdInit: try to allocate 8192 MB
EsStdUnamFileMapInit: shmget() of 8589934592 bytes failed.errno = 28(No space left on device)
EsStdInit: unable to allocate 8192 MB
...
EsStdInit: try to allocate 8 MB
EsStdUnamFileMapInit: shmget() of 8388608 bytes failed.
errno = 28(No space left on device)
EsStdInit: unable to allocate 8 MB
EsStdInit: try to allocate 4 MB
*** ERROR => EsStdInit: unable to allocate 10240 MB [esuxi.c
401]
*** Error 11 while initializing OS dependent part.
*** ERROR => DpEmInit: EmInit (1) [dpxxdisp.c 9559]
*** ERROR => DpMemInit: DpEmInit (-1) [dpxxdisp.c 9486]
*** DP_FATAL_ERROR => DpSapEnvInit: DpMemInit
*** DISPATCHER EMERGENCY SHUTDOWN ***
...
According to 'man 2 shmget' , the error "No space left on device"
(ENOSPC) signifies that the requested memory exceeds the system
limit for Shared Memory (SHMALL).
Therefore, check the value of the sysctl parameter kernel.shmall
(/proc/sys/kernel/shmall).
o ERROR shmget() (22: Invalid argument)
Example from dev_w0:
...
A Fri Oct 22 16:18:47 2005
A
A ---PXA-------------------------------------------
A PXA INITIALIZATION
A System page size: 4kb, admin_size: 31788kb.
I *** ERROR => shmget(11906,1126400000,2016) (22: Invalid
argument) [shmux.c 1904]
A RABAX in run level 1 A RABAX in unkown environment:
task_type=0, run level=1, rabax state=80000000...
![Page 5: 941735](https://reader037.vdocuments.pub/reader037/viewer/2022100218/577d1da71a28ab4e1e8cab5f/html5/thumbnails/5.jpg)
7/31/2019 941735
http://slidepdf.com/reader/full/941735 5/5
19.01.2008 Page 5 of 5
Note 941735 - SAP memory management for 64-bit Linux systems
According to 'man 2 shmget', the error "Invalid argument" (EINVAL)
signifies that you try to create a Shared Memory Segment (in this
case the ABAP program buffer (abap/buffersize) that is larger than
permitted by SHMMAX.
Therefore, check the value of the sysctl parameter kernel.shmmax
(/proc/sys/kernel/shmmax).
Header Data
Release Status: Released for CustomerReleased on: 31.01.2007 16:11:56Priority: Recommendations/additional infoCategory: Consulting
Main Component BC-OP-LNX Linux
Valid Releases
Software Component Release FromRelease
To Release and Following
KRNL64NUC 7.00 7.00 7.00 X
KRNL64NUC 6.40 6.40 6.40 X
KRNL64UC 7.00 7.00 7.00 X
KRNL64UC 6.40 6.40 6.40 X
KRNL64UC 7.10 7.10 7.10 X
Related Notes
Number Short Text
958253 SUSE LINUX Enterprise Server 10: Installation notes
923610 Memory param recommendations for Bank Analyzer 4.2 and 5.0
883726 BIA 7.00: Central Note SAP NetWeaver BI accelerator
797084 SUSE LINUX Enterprise Server 9: Installation notes
386605 SAP Memory Management for Linux (32-bit)
171356 SAP software on Linux: Essential information146289 Parameter Recommendations for 64-Bit SAP Kernel
Attributes
Attribute Value
Operating system LINUX