You were brought to this page based on an internet search
and as a free service to Oracle DBAs.
The text below is an except from the book,
Oracle Performance Firefighting, written by
Craig Shallahamer of
OraPub, Inc.
Figures and tables are not included on this page, only their reference.
To order the book in either print or PDF form, click
here.
©2009, 2010 by Craig Shallahamer. This is copyrighted material.
PleaseOut of respect for those involved in the creation of the book and also for
their familes, we ask you to respect the copyright both in intent and deed. Thank you.
-------------------------------
Oracle provides a special instance parameter that will keep all cursors for all sessions pinned until the cursor is closed. But this benefit comes at the cost of increased shared pool memory consumption, and therefore, the increased likelihood of receiving a 4031 error. Oracle is very aware of this, so to encourage deallocation to free up memory and decrease the likelihood of 4031 errors occurring, the cursor_space_for_time instance parameter is set to false by default.
If a system is experiencing 4031 errors, you should always check the value of cursor_space_for_time. If your system has experienced severe shared pool latch contention at some point in the past, someone may have understandably set cursor_space_for_time to true. While you may not decide to set the parameter to false, it is a valid option and should be seriously considered.
If too many objects have been forced to remain in the shared pool by issuing the dbms_shared_pool.keep procedure, they may be consuming so much memory that Oracle simply may not be able to successfully manage what remains. Also, if a large object is not being kept in the shared pool, the instance has been running for a while, and then the object is referenced, when it is forced to be loaded, the memory may not be available. The key is to not casually keep objects in the shared pool. You should intelligently reduce and refine your pin list, as described earlier in the "Resolving Shared Pool Latch Contention" section.
©2009, 2010 by Craig Shallahamer. This is copyrighted material.
PleaseOut of respect for those involved in the creation of the book and also for
their familes, we ask you to respect the copyright both in intent and deed. Thank you.
|