ORA-04031 on 10g - should I just adjust my SGA POOL SIZE?

Has anyone gotten this message frequently:
ORA-04031: unable to allocate 37536 bytes of shared memory ("shared pool","unknown object","sga heap(1,0)","session parame")
We are a business intelligence application that issues lots of large queries. We just migrated to 10g and we are seeing this every 2-3 days on our testing machine.
In particular, I am not sure about "sga heap"... I would just set my Shared Pool Size higher - currently 144 MB but will this help here? Thoughts?

In Oracle 10g a new feature called "automatic memory management" allows the dba to reserve a pool of shared memory that is used to allocate the shared pool, the buffer cache, the java pool and the large pool.
In general, when the database needs to allocate a large object into the shared pool and cannot find contiguous space available, it will automatically increase the shared pool size using free space from other SGA structure.
Since the space allocation is automatically managed by Oracle, the probability of getting ora-4031 errors may be greatly reduced. Automatic Memory Management is enabled when the parameter SGA_TARGET is greater than zero and the current setting can be obtained quering the v$sga_dynamic_components view.
Please refer to the 10g Administration Manual for further reference
http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14231/toc.htm

Similar Messages

  • ORA-12853 and ORA-04031 simultaneously

    Hello,
    I am getting the following errors when I try to start Oracle
    ORA-12853: insufficient memory for PX buffers: current 0K, max needed 2640K
    ORA-04031: unable to allocate 21544 bytes of shared memory ("large pool","unknown object","large pool","PX msg pool")
    My init.ora file is as follows -
    EDA.__db_cache_size=1174405120
    EDA.__java_pool_size=33554432
    EDA.__large_pool_size=0
    EDA.__shared_pool_size=1174405120
    EDA.__streams_pool_size=0
    *._OPTIM_PEEK_USER_BINDS=FALSE
    *.background_dump_dest='/oracle/EDA/saptrace/background'
    *.compatible='10.2.0'
    *.control_file_record_keep_time=30
    *.control_files='/oracle/EDA/origlogA/cntrl/cntlrEDA.dbf','/oracle/EDA/origlogB/cntrl/cntrlEDA.dbf','/oracle/EDA/sapdata1/cntrl/cntrlEDA.dbf'
    *.core_dump_dest='/oracle/EDA/saptrace/background'
    *.db_block_size=8192
    *.db_cache_size=1159641169
    *.db_files=254
    *.db_name='EDA'
    *.dml_locks=4000
    *.event='10191 trace name context forever, level 1'
    *.FILESYSTEMIO_OPTIONS='setall'
    *.job_queue_processes=1
    *.log_archive_dest='/oracle/EDA/oraarch/EDAarch'
    *.log_buffer=1048576
    *.log_checkpoint_interval=0
    *.log_checkpoints_to_alert=true
    *.open_cursors=800
    *.optimizer_features_enable='10.2.0.1'
    *.pga_aggregate_target=1546188226
    *.processes=80
    *.recyclebin='off'
    *.remote_login_passwordfile='exclusive'
    *.remote_os_authent=true
    *.sessions=96
    *.sga_max_size=2319282339
    *.sga_target=2399141888
    *.shared_pool_reserved_size=115964116
    *.shared_pool_size=1159641169
    *.sort_area_retained_size=0
    *.sort_area_size=2097152
    *.statistics_level='typical'
    *.undo_management='AUTO'
    *.undo_retention=43200
    *.undo_tablespace='PSAPUNDO'
    *.user_dump_dest='/oracle/EDA/saptrace/usertrace'
    *.workarea_size_policy='AUTO'
    According to me everything looks fine. Kindly help me sort this error.
    Thanks in advance.

    1. Play with Shared Pool....
    a. The following query determines the available memory for SHARED_POOL_SIZE in Oracle sga
    select sum (bytes)/1024/1024 from v$sgastat where pool=u2019shared poolu2019
    b. The following query determines the total used memory by shared_Pool in Oracle SGA.
    select sum (bytes)/1024/1024 from v$sgastat where pool=u2019shared poolu2019 and name not in (u2019free memoryu2019)
    c. This is the most important query
    select
    sum(a.bytes)/(1024*1024))shared_pool_used,
    max(b.value)/(1024*1024) shared_pool_size,
    sum(a.bytes)/(1024*1024))-
    (sum(a.bytes)/(1024*1024)) shared_pool_avail,
    ((sum(a.bytes)/(10241024))/(max(b.value)/(10241024)))*100
    pct_shared_pool_avl
    from v$sgastat a, v$parameter b
    where (a.pool=u2019shared poolu2019
    and a.name not in (u2019free memoryu2019))
    and
    b.name=u2019shared_pool_sizeu2019
    You need to continously monitor the shared Pool with the above query at differnet times. During Peak times and Non peak times to have glance of shared pool usage in the Oracle database.
    if the available pct_shared_pool_avl crosses 95% then i think you should re-consider the Process of increasing the shared_pool_size.
    2. There are many way to improve Shared Pool performance.
    a. Ask ABAPers to write more generic and reusablecode.
    b. Using of right block size.
    c. Proper design of the database.
    Comment on ORA-04031 :
    This error should not appear in any of the application logs, the alert log or any trace files. Do not depend on ORA-04031 errors being written to the alert log, as 4031 errors only appear in the alert log if they affect background process operations (such as PMON activities). 4031u2019s are not internal errors and so could be trapped and handled by the application (this is not recommended).
    From 10gR1 onwards, a 4031 trace file is written to the user_dump_dest (or background_dump_dest) directory; this trace file is useful in diagnosing the nature of problem
    Hope this will help you.
    Regards,
    SK
    OCP DBA -9i,10g

  • ORA-04031: unable to allocate 33568 bytes of shared memory  in Oracle 10g

    Hi,
    I am getting following message frequently while taking export in Oracle 10g database:-
    EXP-00008: ORACLE error 4031 encountered
    ORA-04031: unable to allocate 33568 bytes of shared memory ("shared pool","DBMS_REPCAT_UTL","PL/SQL MPCODE","BAMIMA: Bam Buffer")
    ORA-06508: PL/SQL: could not find program unit being called: "SYS.DBMS_REPCAT_UTL"
    ORA-06512: at "SYS.DBMS_REPCAT_EXP", line 87
    ORA-06512: at line 1
    EXP-00083: The previous problem occurred when calling SYS.DBMS_REPCAT_EXP.schema_info_exp
    EXP-00008: ORACLE error 4031 encountered
    ORA-04031: unable to allocate 16416 bytes of shared memory ("shared pool","SELECT SYNNAM, SYNNAM, SYNTA...","kgghtInit","kgghtInit")
    EXP-00000: Export terminated unsuccessfully
    Whats could be the reason?

    There could be a few reasons causing the problem. From literal message it would look like your shared pool size is small and you need to increase. But the root cause of the problem is a little more complicated than that. I suggest you read metalink doc
    Diagnosing and Resolving Error ORA-04031
    Doc ID: Note:146599.1

  • ORA-04031-----capture aborat in stream in oracle 10g R2 in win 2003

    Hi Experts,
    Error Message ORA-04031: unable to allocate 116 bytes of shared memory ("streams pool","unknown object","streams pool","kolcalm coll")
    I got this message for capture ABORTED. my sga_target and sga_max as 1880M. Do I need to increase their size? stream pool size as 880. shared_pool_reserved_size as 14M.
    Based on oracle document for this error message:
    Action: If the shared pool is out of memory, either use the dbms_shared_pool package to pin large packages, reduce your use of shared memory, or increase the amount of available shared memory by increasing the value of the INIT.ORA parameters "shared_pool_reserved_size" and "shared_pool_size". If the large pool is out of memory, increase the INIT.ORA parameter "large_pool_size".
    Key point: we use asm to control. it include share_pool and large_pool. Do we need to increase share pool size?
    Or we need to take other steps to handle this point.
    Thanks for help!!
    regards
    Jim
    Edited by: user589812 on Nov 24, 2008 9:02 AM

    Sorry. I use Oracle 10GR2 in window 2003
    For you sql results as
    STREAMS_POOL_SIZE_FOR_ESTIMATE STREAMS_POOL_SIZE_FACTOR ESTD_SPILL_COUNT ESTD_SPILL_TIME ESTD_UNSPILL_COUNT ESTD_UNSPILL_TIME
    272 .1828 66034094 49261 72443892 114732
    424 .2849 56899900 42916 69761439 110546
    576 .3871 29490067 17904 56631824 87657
    728 .4892 23989724 13951 55330937 85704
    880 .5914 20168762 11552 54131928 83935
    1032 .6935 16931737 9668 52998667 82269
    1184 .7957 14147340 8134 51948431 80724
    1336 .8978 11706951 6797 51052796 79408
    1488 1 9679293 5687 50314492 78322
    1640 1.1022 8051240 4800 49768913 77520
    1792 1.2043 6747253 4087 49361033 76921
    STREAMS_POOL_SIZE_FOR_ESTIMATE STREAMS_POOL_SIZE_FACTOR ESTD_SPILL_COUNT ESTD_SPILL_TIME ESTD_UNSPILL_COUNT ESTD_UNSPILL_TIME
    1944 1.3065 5699093 3515 49064019 76483
    2096 1.4086 4829584 3040 48850903 76171
    2248 1.5108 4089840 2638 48682591 75923
    2400 1.6129 3425461 2278 48542520 75717
    2552 1.7151 2815554 1949 48417853 75535
    2704 1.8172 2267859 1648 48297317 75357
    2856 1.9194 1865779 1427 48178756 75183
    3008 2.0215 1678078 1315 48063018 75014
    3160 2.1237 1637930 1277 47943171 74838
    I am waiting for your help!
    JIm

  • How to troubleshoot ORA-04031 error?

    I'm getting ORA-04031 errors such as the this one:
    ORA-04031: unable to allocate 264 bytes of shared memory ("shared pool","unknown object","PCUR^a9c5b70f","kglob")
    Here is the server's information:
    OS: RHEL
    MEMORY: 48 GB
    There is another database on the same server.
    Here is the information about the database which has the ORA-04031 errors:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    PL/SQL Release 11.2.0.1.0 - Production
    CORE     11.2.0.1.0     Production
    TNS for Linux: Version 11.2.0.1.0 - Production
    NLSRTL Version 11.2.0.1.0 - Production
    Database size (sum of datafiles) is about 2 GB.
    SGA_TARGET = 0
    SGA_MAX_SIZE = 224M -- Since SGA_TARGET = 0, does SGA_MAX_SIZE still control the maximum size of SGA?
    SHARED_POOL_SIZE = 128M
    SHARED_POOL_RESERVED_SIZE = 6710886
    LOG_BUFFER = 4890624
    LARGE_POOL_SIZE = 0
    DB_CACHE_SIZE = 64M
    DB_BLOCK_SIZE = 8192
    JAVA_POOL_SIZE = 24M
    SESSION_CACHED_CURSORS = 50
    STATISTICS_LEVEL = TYPICAL
    MEMORY_TARGET = 0
    MEMORY_MAX_TARGET = 0
    CPU_COUNT = 16
    SQL AREA has 57% GETHITRATIO, 39939 RELOADS, and 1885 INVALIDATIONS.
    Should I just increase SHARED_POOL_SIZE?
    Thanks for any help.

    is your post or mine more understandable?
    SHARED_POOL_SIZE_FOR_ESTIMATE SHARED_POOL_SIZE_FACTOR ESTD_LC_SIZE ESTD_LC_MEMORY_OBJECTS ESTD_LC_TIME_SAVED ESTD_LC_TIME_SAVED_FACTOR ESTD_LC_LOAD_TIME ESTD_LC_LOAD_TIME_FACTOR ESTD_LC_MEMORY_OBJECT_HITS
                              124                   .7561            6                    526             342198                      .991              3331                  16.0918                     705799
                              144                    .878           26                   2018             343203                     .9939              2326                  11.2367                    2162766
                              164                       1           46                   3297             345322                         1               207                        1                    2177631
                              184                   1.122           66                   4698             345433                    1.0003                96                    .4638                    2179067
                              204                  1.2439           86                   6164             345438                    1.0003                91                    .4396                    2179314
                              224                  1.3659          101                   7094             345440                    1.0003                89                      .43                    2179379
                              244                  1.4878          104                   7324             345440                    1.0003                89                      .43                    2179379
                              264                  1.6098          104                   7324             345440                    1.0003                89                      .43                    2179379
                              284                  1.7317          104                   7324             345440                    1.0003                89                      .43                    2179379
                              304                  1.8537          104                   7324             345440                    1.0003                89                      .43                    2179379
                              324                  1.9756          104                   7324             345440                    1.0003                89                      .43                    2179379
                              344                  2.0976          104                   7324             345440                    1.0003                89                      .43                    2179379
    12 rows selected.
    SQL>

  • Diagnosing ORA-04031 on Oracle9iR2

    Hi
    We're running an Oracle9iR2 (9.2.0.6) database on Red Hat Enterprise Linux 4.0 (IA32). The database is used for development and testing. It's been running ok until recently users started getting the following error when trying to connect to the database:
    ORA-04031: unable to allocate 17168 bytes of shared memory ("shared pool","unknown object","sga heap(1,0)","session param values")
    What's changed during the last weeks is that we've installed Oracle10gR2 and the Oracle Calendar server on the machine, and added a about 10-20 new user accounts.
    The server was originally running in dedicated server mode until i noticed there were 115 Oracle processes running on the server at one moment. The database typically has large number of connections which are idle most of the time. I changed it to shared server mode in order to avoid the overhead of having lots of server processes which are doing nothing most of the time.
    I also increased the shared_pool_size and large_pool_size on the server but i'm still seeing ORA-04031 errors in trace files. How do i determine whether the cause is shared or large pool? How do i determine the right sizes for these pools? The traces include heap dumps for large pool.
    The SQL query appearing in the trace files cursor name section is just one type of SQL query in most of the cases. How can i debug shared memory usage for a particular SQL query so that i can try and modify it to a more memory economic direction?
    br. aspa

    Hi,
    If you have access to metalink, I advise you to read 146599.1 Diagnosing and Resolving Error ORA-04031.
    The SQL query appearing in the trace files cursor name section is just one type of SQL
    query in most of the cases. How can i debug shared memory usage for a particular SQL
    query so that i can try and modify it to a more memory economic direction?The following SQL can show you statements with literal values or candidates to include bind variables:
    SELECT substr(sql_text,1,40) "SQL",
    count(*) ,
    sum(executions) "TotExecs"
    FROM v$sqlarea
    WHERE executions < 5
    GROUP BY substr(sql_text,1,40)
    HAVING count(*) > 30
    ORDER BY 2;Note: The number "30" in the having section of the statement can be adjusted as needed to get more detailed information.
    There is a fixed table called x$ksmlru that tracks allocations in the shared pool that cause other objects in the shared pool to be aged out. This fixed table can be used to identify what is causing the large allocation.
    SELECT * FROM X$KSMLRU WHERE ksmlrsiz > 0;Note : This view can only be queried by connected as the SYS.
    How have you RAM ?
    Since your last install, perhaps your RAM is not sufficient any more ?
    Check your memory occupation.
    Nicolas.
    How do i determine whether the cause is shared or large pool? If there is no free memory into large pool left when a request is made then an ORA-4031 will be signalled similar to this : ORA-04031: unable to allocate XXXX bytes of shared memory
    ("large pool","unknown object","session heap","frame")
    Message was edited by:
    N. Gasparotto

  • ORA-00604: error occurred at recursive SQL level 1 + ORA-04031

    Hi,
    SQL> select * from v$version;
    BANNER
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bi
    PL/SQL Release 10.2.0.1.0 - Production
    CORE    10.2.0.1.0      Production
    TNS for Solaris: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    os version : SunOS oratest 5.10 Generic_127127-11 sun4u sparc SUNW,Sun-Fire-V210
    SQL> show parameter  sga_target
    NAME                                 TYPE        VALUE
    sga_target                           big integer 892M
    SQL> show parameter shared_pool_size
    NAME                                 TYPE        VALUE
    shared_pool_size                     big integer 112M
    when i do normal query i am getting ora-04031 error and 10g server is Automatic Shared Memory Management since i set sga_target and server as to do automatically readjusts the sizes of memory pools, if that is the case why it throwing ora-04031 error;
    below errors showing before bounce the database
    SQL> show parameter size
    ORA-04031: unable to allocate 3840 bytes of shared memory ("shared
    pool","unknown object","sga heap(1,0)","kglsim object batch")
    SQL> select * from tab
      2  ;
    select * from tab
    ERROR at line 1:
    ORA-04031: unable to allocate 3840 bytes of shared memory ("shared
    pool","select * from tab
    ","sga heap(1,0)","kglsim object batch")
    alert log file:
    Errors in file /oracle/admin/appsdb/bdump/appsdb_smon_19154.trc:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-04031: unable to allocate 3840 bytes of shared memory ("shared pool","unknown object","sga heap(1,0)","kglsim object batc
    h")
    Thanks
    PrakashEdited by: prakashdba on Jan 10, 2009 12:31 AM
    Edited by: prakashdba on Jan 10, 2009 4:10 AM

    And your version number is?
    And your patch level is?
    And your hardware and operating system are?
    What did you find when you looked this up at metalink?
    Did you follow the advice in the metalink Knowledge Base docs?

  • Urgent help with memory issue (ORA-04031)

    Hi Geeks,
    Came Across this below error in alert log in of our databases. Interestingly this error only pops up while the database backup runs. Below are the memory parameters.
    memory_max_target big integer 14G
    memory_target big integer 13G
    pga_aggregate_target big integer 0
    sga_target big integer 0
    shared_pool_reserved_size big integer 192M
    shared_pool_size big integer 0
    ORA-04031: unable to allocate 5792 bytes of shared memory
    ("shared pool","unknown object","sga heap(1,1)","ges resource ")
    Errors in file /apps/opt/oracle/diag/asm/+asm/+ASM1/trace/+ASM1_lmd0_14123.trc
    I have tried specifying a value to shared_pool_size but with no luck..!! Pls help. I am not sure how to resolve this.

    Hi, ORA-4031 in this case can be caused by unrestricted growth of the PGA, thus forcefully reducing the SGA.
    We've had this in the past also.
    The solution is in older versions to increase the shared_pool_size as you mentioned but with ASMM, this is no longer an option. You can however retrict the growth of the PGA by setting SGA_TARGET.
    On our system this now looks like:
    SQL> show parameter _target
    NAME                                 TYPE                 VALUE
    db_flashback_retention_target        integer              1440
    memory_max_target                    big integer          10G
    memory_target                        big integer          10G
    pga_aggregate_target                 big integer          0
    sga_target                           big integer          8GSee how we in fact set the max growth of the PGA to 2Gb ( 10Gb - 8Gb)
    Try this and see if ot works for you also
    Success!!
    FJFranken

  • ORA-00604, ORA-04031

    How can I handle this error message?
    ERROR:
    ORA-00604: error occurred at recursive SQL level 2
    ORA-04031: unable to allocate 4048 bytes of shared memory ("shared pool","TRIGGER$","sga heap","state objects")
    ORA-00604: error occured at recursive SQL levle1
    ORA-04031: unable to allocate 4048 bytes of shred memory
    ("shared pool","unknown object","sga heap","state objects")
    I changed shared_pool_size.
    Initial shared_pool_size is 52428800
    and I changed it to 1500000000.
    Isn't 150M enough?
    Should I have to set shared_pool_size to lager size?
    Or is there any other way to fix this problem?
    Oracle Version is 8.1.6.
    Platform is SGI , IRIX 6.4.10+.
    Please, help me.
    Tanki

    - Use bind variables in your applications (if they are not used allready)
    - Pin larger packages (the ones you actaully use) immediately uppon database startup
    - Increase your shared pool (if it's not unreasonably large allready)
    - ALTER SYSTEM FLUSH SHARED_POOL; when you encounter ORA-4031 (this is more of a temporary workaround than a real sollution)

  • ORA-04031 Errors

    So I am running Oracle 11g and APEX 4.2.1.00.08 on an Amazon m1.medium instance. I also have it running on a Dell T300 server locally. I haven't had any issues with application on the local server, but I keep getting memory errors on the Amazon one. This is the error message " ORA-04031: unable to allocate 32792 bytes of shared memory ("large pool","unknown object","session heap","kgich") "
    I have checked the shared memory pool on both machines. Here is what "select * from v$sgainfo; " shows from both machines if that is of any use: [Amazon Machine|http://diversifiedindustries.biz/images/AmazonOracle.jpg] [Local Machine|http://diversifiedindustries.biz/images/DIOracle.jpg] I am not sure how to interpret these results as I am a noob when it comes to Oracle and Apex things.
    Any thoughts on how I can fix this?

    I had originally posted in the APEX forum and it was suggested I try here, which is why I had only put the APEX version. I know now to post everything in the future.
    jgarry wrote:
    Please show us the output of this command:
    show parameter pool
    SQL> show parameter pool
    NAME                                 TYPE        VALUE
    buffer_pool_keep                     string
    buffer_pool_recycle                  string
    global_context_pool_size             string
    java_pool_size                       big integer 0
    large_pool_size                      big integer 0
    olap_page_pool_size                  big integer 0
    shared_pool_reserved_size            big integer 8178892
    shared_pool_size                     big integer 100M
    streams_pool_size                    big integer 0
    Also, you can create a pfile from spfile, and post that.
    xe.__db_cache_size=8388608
    xe.__java_pool_size=4194304
    xe.__large_pool_size=4194304
    xe.__oracle_base='C:\oraclexe\app\oracle'#ORACLE_BASE set from environment
    xe.__pga_aggregate_target=16777216
    xe.__sga_target=192937984
    xe.__shared_io_pool_size=4194304
    xe.__shared_pool_size=163577856
    xe.__streams_pool_size=4194304
    *.audit_file_dest='C:\oraclexe\app\oracle\admin\XE\adump'
    *.compatible='11.2.0.0.0'
    *.control_files='C:\oraclexe\app\oracle\oradata\XE\control.dbf'
    *.db_name='XE'
    *.DB_RECOVERY_FILE_DEST_SIZE=10G
    *.DB_RECOVERY_FILE_DEST='C:\oraclexe\app\oracle\fast_recovery_area'
    *.diagnostic_dest='C:\oraclexe\app\oracle\.'
    *.dispatchers='(PROTOCOL=TCP) (SERVICE=XEXDB)'
    *.job_queue_processes=4
    *.memory_target=200M
    *.open_cursors=300
    *.remote_login_passwordfile='EXCLUSIVE'
    *.sessions=20
    *.shared_pool_size=104857600
    *.shared_servers=4
    *.undo_management='AUTO'
    *.undo_tablespace='UNDOTBS1'

  • ORA-04031 during export on CTX-index

    Hi !
    I get ORA-04031 during export when an interMedia CTX-Index should get exported. The exact error message is:
    unable to allocate 4072 bytes of shared memory ("shared pool", "DBMS_SYS_SQL", "PL/SQL MPCODE", "BAMIMA: BAM Buffer")
    followed by
    ORA-06508: PL/SQL: could not find program unit being called
    ORA-06512: in "SYS.DBMS_SQL", line 9
    ORA-06512: in "SYS.DBMS_EXPORT_EXTENSION", line 244
    Any hints for me what I could do?
    TIA,
    Stefan

    Interesting.  You should open a  thread with a more relevant title about views with pk / fk constraints.
    I don't have a way to solve your problem --- to identify such views.
    Hemant K Chitale

  • ORA-04031 question

    We got a ORA-04031: unable to allocate 32 bytes of shared memory ("shared pool","select name,online$,contents...","sql area","tmp"). (BTW. What does this "tmp" mean?)
    Noone was able to login to server for about 5 minutes and then it came back to life.
    I queried system views, and found out that during the time when database was unavalable, our ASMM tried to grow shared pool and shring buffer cache. It returned an error about 300 times, and (around the time when db came to life) suceeded increasing shared pool from 304 MB to 320 MB.
    How can i find out what cused the errors during the resize?
    Besides that, free memory in shared pool was 164 MB. I did found this document 451960.1, suggesting it could be a bug (not sure if it's fixed in later versions though).
    Also, one side question. What exactly is "KGH: NO ACCESS" part of shared pool? As i understand that part is the memory that is in transit during the resizing of buffer cache/shared pool. But why is it so large all the time (400 MB in my case) ? Should it ever shrink? Resize is not happening all the time, and when it is, it's not that large.
    Database is 10.2.0.2 on AIX.

    You need to open TAR in Oracle support.
    You can also check streams pool size parameter (it is exists in 9.2.0.6). By default Oracle allocated 10% of shared pool for streams but started from 9.2.0.6 you can change streams pool size. There is some minimum recomendation for streams pool. Looks like your streams pool is very small.

  • ORA-10631: SHRINK clause should not be specified for this object

    Hi
    I was trying to shrink table to reset the high water mark but some unknown reason it failed.
    Please help me
    SQL> declare
    stmt varchar2(100);
    cursor cur is
    select object_name from user_objects where substr(object_name,1,1)='A'
    and object_type='TABLE';
    begin
    for i in cur loop
    stmt :='alter table '||i.object_name ||' shrink space';
    execute immediate stmt;
    end loop;
    END;
    declare
    ERROR at line 1:
    ORA-10631: SHRINK clause should not be specified for this object
    ORA-06512: at line 9
    Regards
    Jewel

    http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_3001.htm#CJA
    The shrink clause lets you manually shrink space in a table, index-organized table or its overflow segment, index, partition, subpartition, LOB segment, materialized view, or materialized view log. This clause is valid only for segments in tablespaces with automatic segment management. By default, Oracle Database compacts the segment, adjusts the high water mark, and releases the recuperated space immediately.
    Compacting the segment requires row movement. Therefore, you must enable row movement for the object you want to shrink before specifying this clause. Further, if your application has any rowid-based triggers, you should disable them before issuing this clause.

  • Increase Shared Pool for erorr # ORA-04031

    hi,
    what do i need to look at before i increase the shared pool of our database?
    there is just the one database instance on the machine.
    i am concerned about the repurcussions on the server.
    i hope the information below is of help.
    db version: 10.2.0.1.0
    os: Red Hat Linux 3
    SQL> select name, value from v$parameter where name like '%pool%';
    name value
    shared_pool_size 150994944
    large_pool_size 33554432
    java_pool_size 50331648
    streams_pool_size 0
    shared_pool_reserved_size 10066329
    buffer_pool_keep
    buffer_pool_recycle
    global_context_pool_size
    olap_page_pool_size 0
    thanks,
    santosh sewlal

    Hi Santosh,
    This is what i faced last two days back! Now i am monitoring the Issue! If you got any solutions please let me know how to avoid this!
    ORA-04031 error can be due to either an inadequeate sizing of the SHARED POOL size or due to heavy
    fragmentation leading the database to not finding large enough chuncks of memory.
    You can monitor this with the two events...
    alter system set events '4031 trace name errorstack level 3';
    alter system set events '4031 trace name heapdump level 3';
    Fragmentataion is one of the causes of ora 4031
    Please refer these.
    1.Article-ID: Note 146599.1
    Title: Diagnosing and Resolving Error ORA-04031
    2.Article-ID: Note 62143.1
    Title: Understanding and Tuning the Shared Pool
    3.Article-ID: Note 61623.1
    This is paticular for Oracle 9i Rel 2, Hope the same for Oracle 10 G
    Regards
    Ravi

  • ORA-04031 error in 8i

    Hi Sir,
    I am installing oracle 8.1.5 on a windows 2003 server R2 SP2
    machine, its having 4GB of RAM.
    I have choosen to install the preconfigured starter DB, when DBCA is creating
    the DB is throws the following error message...
    ORA-04031 unable to allocate 102724472 bytes of shared memory
    ("shared pool","unknown object","sga heap","db_block_buffers")
    Then Ignore or abort comes.
    Please give me any solution.
    Edited by: Wason Naveen on Nov 7, 2009 4:15 AM

    Hello,
    In general ORA-4031 is an error due to a lack of memory (shared_pool).
    So you should check for the parameter SHARED_POOL_SIZE and increase it (for instance to 200 Mo).
    Else, about the release, I'm surprised that you use Oracle 8.1.5. It's an old release and I'm not sure it's
    certified on Windows 2003.
    Best regards,
    Jean-Valentin

Maybe you are looking for