dbTalk Databases Forums  

High PGA memory usage fetching into Varrays

comp.databases.oracle.misc comp.databases.oracle.misc


Discuss High PGA memory usage fetching into Varrays in the comp.databases.oracle.misc forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
sideyt
 
Posts: n/a

Default High PGA memory usage fetching into Varrays - 01-10-2008 , 09:43 AM






1) What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.

3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?

Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.

Reply With Quote
  #2  
Old   
Michael Austin
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-12-2008 , 09:27 PM






sideyt wrote:
Quote:
1) What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.

3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?

Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
What is your SGA size? How much memory in the box? what is the EXACT
error message - there are many relating to "out of memory". Sounds like
you have some tuning to do and/or upgrading the hardware to be able to
accommodate the workload it is being asked to do.



Reply With Quote
  #3  
Old   
Michael Austin
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-12-2008 , 09:27 PM



sideyt wrote:
Quote:
1) What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.

3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?

Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
What is your SGA size? How much memory in the box? what is the EXACT
error message - there are many relating to "out of memory". Sounds like
you have some tuning to do and/or upgrading the hardware to be able to
accommodate the workload it is being asked to do.



Reply With Quote
  #4  
Old   
Michael Austin
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-12-2008 , 09:27 PM



sideyt wrote:
Quote:
1) What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.

3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?

Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
What is your SGA size? How much memory in the box? what is the EXACT
error message - there are many relating to "out of memory". Sounds like
you have some tuning to do and/or upgrading the hardware to be able to
accommodate the workload it is being asked to do.



Reply With Quote
  #5  
Old   
Michael Austin
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-12-2008 , 09:27 PM



sideyt wrote:
Quote:
1) What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.

3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?

Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
What is your SGA size? How much memory in the box? what is the EXACT
error message - there are many relating to "out of memory". Sounds like
you have some tuning to do and/or upgrading the hardware to be able to
accommodate the workload it is being asked to do.



Reply With Quote
  #6  
Old   
joel garry
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-14-2008 , 04:02 PM



On Jan 10, 7:43*am, sideyt <sid... (AT) hotmail (DOT) com> wrote:
Quote:
1) *What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.
Have support help you with heap dumps to really see what is going on.
Also google for what Jonathan Lewis has written on
pga_aggregate_target. You may need to be handling the pga sizing
manually simply because of what you do. If the memory issue is too
big, you may want to _decrease_ sort area size to force more passes.
Remember you can do things differently per session, you may want to
futz with things for your specific app. Metalink Note:223730.1 is a
pretty good primer.

Quote:
3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?
From metalink Note:284951.1 (please ignore what it says about hit
ratios):

select
name,
to_char(decode( unit,'bytes', value/1024/1024,
value ),'999,999,999.9') value,
decode( unit, 'bytes', 'mbytes', unit ) unit
from
v$pgastat
/

Then check out mult-pass usage, either through OEM or google for how
to check it.

If you are doing indexed access before or between your in-memory
stuff, that free_unused_user_memory procedure may simply be what you
need.

Quote:
Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". *We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
If you are using RAC, there are mysterious unpublished bugs about PGA
memory leaks in 10.2.0.3.0. Who knows if they apply to non-RAC? You
might consider pushing support for a fix if you can demonstrate a
problem in the latest patch set.

Note:304215.1 is kind of interesting.

jg
--
@home.com is bogus.
One poll's prediction of who would win in New Hampshire:
78% Ron Paul
8% John McCain
6% Mike Huckabee
5% Mitt Romney
2% Rudy Giuliani
1% Fred Thompson



Reply With Quote
  #7  
Old   
joel garry
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-14-2008 , 04:02 PM



On Jan 10, 7:43*am, sideyt <sid... (AT) hotmail (DOT) com> wrote:
Quote:
1) *What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.
Have support help you with heap dumps to really see what is going on.
Also google for what Jonathan Lewis has written on
pga_aggregate_target. You may need to be handling the pga sizing
manually simply because of what you do. If the memory issue is too
big, you may want to _decrease_ sort area size to force more passes.
Remember you can do things differently per session, you may want to
futz with things for your specific app. Metalink Note:223730.1 is a
pretty good primer.

Quote:
3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?
From metalink Note:284951.1 (please ignore what it says about hit
ratios):

select
name,
to_char(decode( unit,'bytes', value/1024/1024,
value ),'999,999,999.9') value,
decode( unit, 'bytes', 'mbytes', unit ) unit
from
v$pgastat
/

Then check out mult-pass usage, either through OEM or google for how
to check it.

If you are doing indexed access before or between your in-memory
stuff, that free_unused_user_memory procedure may simply be what you
need.

Quote:
Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". *We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
If you are using RAC, there are mysterious unpublished bugs about PGA
memory leaks in 10.2.0.3.0. Who knows if they apply to non-RAC? You
might consider pushing support for a fix if you can demonstrate a
problem in the latest patch set.

Note:304215.1 is kind of interesting.

jg
--
@home.com is bogus.
One poll's prediction of who would win in New Hampshire:
78% Ron Paul
8% John McCain
6% Mike Huckabee
5% Mitt Romney
2% Rudy Giuliani
1% Fred Thompson



Reply With Quote
  #8  
Old   
joel garry
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-14-2008 , 04:02 PM



On Jan 10, 7:43*am, sideyt <sid... (AT) hotmail (DOT) com> wrote:
Quote:
1) *What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.
Have support help you with heap dumps to really see what is going on.
Also google for what Jonathan Lewis has written on
pga_aggregate_target. You may need to be handling the pga sizing
manually simply because of what you do. If the memory issue is too
big, you may want to _decrease_ sort area size to force more passes.
Remember you can do things differently per session, you may want to
futz with things for your specific app. Metalink Note:223730.1 is a
pretty good primer.

Quote:
3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?
From metalink Note:284951.1 (please ignore what it says about hit
ratios):

select
name,
to_char(decode( unit,'bytes', value/1024/1024,
value ),'999,999,999.9') value,
decode( unit, 'bytes', 'mbytes', unit ) unit
from
v$pgastat
/

Then check out mult-pass usage, either through OEM or google for how
to check it.

If you are doing indexed access before or between your in-memory
stuff, that free_unused_user_memory procedure may simply be what you
need.

Quote:
Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". *We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
If you are using RAC, there are mysterious unpublished bugs about PGA
memory leaks in 10.2.0.3.0. Who knows if they apply to non-RAC? You
might consider pushing support for a fix if you can demonstrate a
problem in the latest patch set.

Note:304215.1 is kind of interesting.

jg
--
@home.com is bogus.
One poll's prediction of who would win in New Hampshire:
78% Ron Paul
8% John McCain
6% Mike Huckabee
5% Mitt Romney
2% Rudy Giuliani
1% Fred Thompson



Reply With Quote
  #9  
Old   
joel garry
 
Posts: n/a

Default Re: High PGA memory usage fetching into Varrays - 01-14-2008 , 04:02 PM



On Jan 10, 7:43*am, sideyt <sid... (AT) hotmail (DOT) com> wrote:
Quote:
1) *What are the real bytes per value (RAM) associated with each
element of a Varray of NUMBER? (Of INTEGER, of PLS_INTEGER, of
VARCHAR2(20) etc).We are using arrays with more than 1 million
elements and often get PGA usage in the gigabytes.

2) What else (besides sorting) contributes to high PGA usage? We often
do bulk collect (with row limits) of SDO_geometries and this seems to
easily generate out of memory errors unless we use small row limits
like 500.
Have support help you with heap dumps to really see what is going on.
Also google for what Jonathan Lewis has written on
pga_aggregate_target. You may need to be handling the pga sizing
manually simply because of what you do. If the memory issue is too
big, you may want to _decrease_ sort area size to force more passes.
Remember you can do things differently per session, you may want to
futz with things for your specific app. Metalink Note:223730.1 is a
pretty good primer.

Quote:
3) Are there any strategies (besides
dbms_session.free_unused_user_memory ) to free memory and keep PGA
memory usage lower?
From metalink Note:284951.1 (please ignore what it says about hit
ratios):

select
name,
to_char(decode( unit,'bytes', value/1024/1024,
value ),'999,999,999.9') value,
decode( unit, 'bytes', 'mbytes', unit ) unit
from
v$pgastat
/

Then check out mult-pass usage, either through OEM or google for how
to check it.

If you are doing indexed access before or between your in-memory
stuff, that free_unused_user_memory procedure may simply be what you
need.

Quote:
Our environment is 64 bit Blade servers running Linux: Oracle Database
10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I would prefer real answers to these questions - not avoidance answers
like "don't use Varrays". *We are performing spatial algorithms in
core - and are using PL/SQL successfully except for this
limitation.Thank you.
If you are using RAC, there are mysterious unpublished bugs about PGA
memory leaks in 10.2.0.3.0. Who knows if they apply to non-RAC? You
might consider pushing support for a fix if you can demonstrate a
problem in the latest patch set.

Note:304215.1 is kind of interesting.

jg
--
@home.com is bogus.
One poll's prediction of who would win in New Hampshire:
78% Ron Paul
8% John McCain
6% Mike Huckabee
5% Mitt Romney
2% Rudy Giuliani
1% Fred Thompson



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.