cancel
Showing results for 
Search instead for 
Did you mean: 

TSV_TNEW_PAGE_ALLOC_FAILED..

0 Kudos

Hello Guru

We have a cutomizied program which is using very large internal table aobut 4 GB.

Don't say that change the program plz.

Following is short dump

-


Short text

No more storage space available for extending an internal table.

What happened?

You attempted to extend an internal table, but the required space was

not available.

.......

.......

How to correct the error

The amount of storage space (in bytes) filled at termination time was:

Roll area.......................................... 6238048

Extended memory (EM)............. 2002747344

Assigned memory (HEAP)........ 1998558848

Short area................................................ " "

Paging area........................................ 32768

Maximum address space......... 2140888928

-


According to the shout dump, I've raised the parameters like folliowing (in real system)

ztta/roll_area ....................................20000000

ztta/roll_extension.........................2500000000

abap/heap_area_total...................2500000000

abap/heap_area_dia.....................2500000000

abap/heap_area_nondia...............2500000000

em/initial_size_MB.....................................4096

(for reference, ztta/max_memory_MB is 2047 and ztta/roll_first is 1)

I gave EM memory enough but in real EM used around 2GB, 500MB isn't used.

When I checked memory status in OS level, 3GB is still unused but the program cancelled.

How can fix it?

Accepted Solutions (1)

Accepted Solutions (1)

desiree_matas
Contributor
0 Kudos

Hello Duc Soo Kim,

This type of dump occurs due the heap memory consumes, so the relevant parameters to check would be:

abap/heap_area_dia

abap/heap_area_nondia

abap/heap_area_total

When Extended Memory is used up, the process will go into PRIV mode as it starts using Heap Memory (or vise-versa). No other user will be able to use this wp while it is in PRIV mode. If there is enough heap for it to finish, you will not see the error TSV_NEW_PAGE_ALLOC_FAILED and the wp will be freed.

If it is a 64 bit system then check note 146289 (it explains how to implement SAP profile parameters). Also SAP Note 425207 for parameter limitations should be interesting here. Setting of em/initial_size_MB usually depends on the physical RAM on the server and if you have any other instances on that same server. According to note #146289 this can be increased to very high values if there is sufficent RAM on the box.

Regards,

Désiré

Answers (4)

Answers (4)

sandeep_kumar60
Participant
0 Kudos

hi

iam also facing the similar situation , could you help me with your solution please

Former Member
0 Kudos

Sandeep the solution is already in the thread. This type of dump can occur in many situations.

You can go through the parameters mentioned above .

Regards

Amit Padmawar

michael_mulvey
Employee
Employee
0 Kudos

Hi,

Can you let me know what you did to solve this issue? I am very interested

Michael

0 Kudos

Thank you for your advice

I've performed the program again after chaging 2 parameters,

- abap/heap_area_total from 3GB to 5GB

- abap/heap_area_nondia from 3GB to 5GB

but still it couldn't work.

This below are parts of short dump

-


At the time of the termination, the following data was determined for

the relevant internal table:

Memory location: "Session memory" ================== No.F

Row width: 326

Number of rows: 0 ================== No.G

Allocated rows: 7593008 ================== No.H

Newly requested rows: 32 (in 237281 blocks) ================== No.I

How to correct the error

The amount of storage space (in bytes) filled at termination time was:

Roll area...................... 19,748,848 ================== No.A

Extended memory (EM)........... 3,004,121,016 ================== No.B

Assigned memory (HEAP)......... 2,067,091,728 ================== No.C

Short area..................... " "

Paging area.................... 32,768 ================== No.D

Maximum address space.......... 2,140,774,416 ================== No.E

-


I have lots of question on this result:

Q1>I can understand No.A, it is corresponding with my parameter "ztta/roll_area = 20000000", right?

Q2>What is the right parameter for No.B, Extended Memory(EM)? "em/initial_size_MB"? or "ztta/roll_extension"? or something else? For reference my "em/initial_size_MB" is set to 8GB and "ztta/roll_extension" is 3GB.

Q3>I've assigned 5GB for heap memory as setting the parameter "abap/heap_area_nondia" to 5GB, but the program used just around 2GB and it's cancelled with short dump. Could you explain it?

Q4>What is the parameter for paging area? Look No.D please.

Q5>What is "Maximum address space"? and what parameter is for it?

Q6>I've confused on No.F~I also. Especially on No.I, this means 32row(in 237281 blocks) is needed for finishing this job? so 237281 blocks means that 237281em/block_size? or 237281 db_block_size(oracle)?

Q6>On No.D I've set a parameter 'rdisp/PG_MAXFS' to 131072 but the amount of pagaing area(see above) is 32768. How could it be? For reference 'rdisp/PG_SHM' is 16384.

Thanks in advance.

Former Member
0 Kudos

Let me put things straight and short (i cannot explain every parameter, that is why documentation was invented):

- you said you are running in background

- background work processes allocate memory from heap first (abap/heap_area_nondia), second from extended memory (ztta/roll_extension). This does not apply if you are on windows.

So what you need is to increase abap/heap_area_nondia (remember abap/heap_area_nondia < abap/heap_area_total). And don't run out of physical memory, otherwise you will be screwed.

Cheers Michael

0 Kudos

Thank you for all.

I've found a parameter "ztta/max_memreq_MB".

On RZ 11 it's short discription says "Limit for a single request to memory"

On my short dump always it is terminated around 2GB. (ztta/max_memreq_MB is set to 2047)

So I'll try set it to 3076. But the maximum value is 2048 on RZ11.

Result of web searing, Someone says it could be greater than 2048.

Is it okay for setting to 2048 or higher?

michael_mulvey
Employee
Employee
0 Kudos

Hi,

So you want to place an internal table of 4gb into a workprocess with only 2,384Mb (abap/heap_area_total = 2500000000) then you will run out of memory. So to solve your problem you will have to increase the abap/heap_area_total to a value like 10Gb (abap/heap_area_total = 10737418240) and abap/heap_area_dia = 5GB (abap/heap_area_dia = 5368709120).

So I will go over the parameters again and explain why I have set them like this:-

abap/heap_area_total = Defines the limit for the total amount of heap memory allocated to all work processes. The reason why I set this as 10GB as this is the total amount of memory that ALL workprocesses use. This is the upper limit you are reaching causing the TSV_TNEW_PAGE_ALLOC_FAILED. 10GB will allow 2 work processes to use all memory if parameter below has been set as I recommend.

abap/heap_area_dia = Defines the limit for the amount of local memory allocated to dialog work processes. In your case I have entered 5Gb as this limit as this will allow a 4Gb internal table and some room for user context without the workprocess going into PRIV mode.

In this case I have only calculated for 2 workprocesses using all the available heap memory (10Gb). If you have more available (and you HAVE to be running 64Bit OS as the upper addressible memory limit for 32Bit is 4Gb TOTAL including OS. Approx 3Gb TOTAL for SAP) then you will have to add this into the abap/heap_area_total.

P.S. The values I have provided are only guides. You might have to modify them for more workprocesses. Also you should read the zero memory management section for more information on memory and SAP on 64bit OS.

Michael

0 Kudos

Thanks for anwser.

It seems like 2 ways to solve it.

First, increasing "em/initial_size_MB" enoughly for process not to use heap memory

Second, increasing "abap/heap_area_nondia(it is performed as background job)" over 4GB

Can you tell me I understand what you said correctly?

Another questions, look below please:

My program that is using large internal table is batch process, not dialog process, so that I should set "abap/heap_area_NONdia" not "abap/heap_area_dia", right?

Free memory(physical) 3GB on my machine generally, so if I set "abap/heap_area_total" 2.5GB to 5.5GB, the memory will be full?

If I set this, the physical memory is assigned in real? or when some proecss requires the memory, it is assigned?

michael_mulvey
Employee
Employee
0 Kudos

Hi,

You seem to have a number of questions here. I will try to answer them one by one.

(Q) First, increasing "em/initial_size_MB" enoughly for process not to use heap memory

(A) Correct. If the em/initial_size_MB is large enough to handle the request then no heap memory will be used (abap/heap_area_nondia for batch wp) and the workprocesses will not go into PRIV mode. However em/initial_size_MB will be used for ALL workprocesses so this needs to be set high.

(Q)Second, increasing "abap/heap_area_nondia(it is performed as background job)" over 4GB

Can you tell me I understand what you said correctly?

(A) If you increase the abap/heap_area_nondia parameter to be able to process 4GB table then you will not have the TSV_TNEW_PAGE_ALLOC_FAILED shortdump.

(Q) My program that is using large internal table is batch process, not dialog process, so that I should set "abap/heap_area_NONdia" not "abap/heap_area_dia", right?

(A) Correct. The abap/heap_area_NONdia parameter is specificall for batch processes and will not effect dia wp.

(Q) Free memory(physical) 3GB on my machine generally, so if I set "abap/heap_area_total" 2.5GB to 5.5GB, the memory will be full?

(A) The physical memory could possibly be full however not all the memory will be used. There is always the pagefile (if on windows, swap on Unix) that can be addressed. SAP does not have any control on what memory will be provided as this handled by the OS, either physical or swap. So if your OS is configured to address 10Gb or even 20Gb this can be provided by a large enough pagefile + physical memory.

(Q) If I set this, the physical memory is assigned in real? or when some proecss requires the memory, it is assigned?

(A) No. SAP does not handle memory allocation. This is handled by the OS.

Michael

Former Member
0 Kudos

Please don't change the program, do not even think about it.

Changing the program will only...

- make it run faster

- save system resources allowing more concurrent users (in your case more than one)

- not screw up your system by changing your memory configuration

Just my opinion no offense

But if you still want to do it, then we would need to know if you run the program in dialog or batch. And which platform (operating system) is also a point of interest, because they handle the memory management differently. But you can also read the documentation Desiree mentioned. These are most probably correct if you are running in dialog, you might also want to increase em/initial_size_MB then.

Cheers Michael