Managing memory Automatic Memory Management 2

When MEMORY_MAX_TARGET is >0 and MEMORY_TARGET=0 how is memory managed?

It is managed as described in the documentation available at http://tahiti.oracle.com for free.
As there is documentation on-line, please avoid asking to abstract the documentation.
Your question constitutes a violation of Forum Etiquette.
Sybrand Bakker
Senior Oracle DBA

Similar Messages

  • Questions about db_keep_cache_size and Automatic Shared Memory Management

    Hello all,
    I'm coming upon a server that I'm needing to pin a table and some objects in, per the recommendations of an application support call.
    Looking at the database, which is a 5 node RAC cluster (11gr2), I'm looking to see how things are laid out:
    SQL> select name, value, value/1024/1024 value_MB from v$parameter
    2 where name in ('db_cache_size','db_keep_cache_size','db_recycle_cache_size','shared_pool_size','sga_max_size');
    NAME VALUE VALUE_MB
    sga_max_size 1694498816 1616
    shared_pool_size 0 0
    db_cache_size 0 0
    db_keep_cache_size 0 0
    db_recycle_cache_siz 0 0
    e
    Looking at granularity level:
    SQL> select granule_size/value from v$sga_dynamic_components, v$parameter where name = 'db_block_size' and component like 'KEEP%';
    GRANULE_SIZE/VALUE
    2048
    Then....I looked, and I thought this instance was set up with Auto Shared Mem Mgmt....but I see that sga_target size is not set:
    SQL> show parameter sga
    NAME TYPE VALUE
    lock_sga boolean FALSE
    pre_page_sga boolean FALSE
    sga_max_size big integer 1616M
    sga_target big integer 0
    So, I'm wondering first of all...would it be a good idea to switch to Automatic Shared Memory Management? If so, is this as simple as altering system set sga_target =...? Again, this is on a RAC system, is there a different way to do this than on a single instance?
    If that isn't the way to go...let me continue with the table size, etc....
    The table I need to pin is:
    SQL> select sum (blocks) from all_tables where table_name = 'MYTABLE' and owner = 'MYOWNER';
    SUM(BLOCKS)
    4858
    And block size is:
    SQL> show parameter block_size
    NAME TYPE VALUE
    db_block_size integer 8192
    So, the space I'll need in memory for pinning this is:
    4858 * 8192 /1024/1024 = 37.95.......which is well below my granularity mark of 2048
    So, would this be as easy as setting db_keep_cache_size = 2048 with an alter system call? Do I need to set db_cache_size first? What do I set that to?
    Thanks in advance for any suggestions and links to info on this.
    cayenne
    Edited by: cayenne on Mar 27, 2013 10:14 AM
    Edited by: cayenne on Mar 27, 2013 10:15 AM

    JohnWatson wrote:
    This is what you need,alter system set db_keep_cache_size=40M;I do not understand the arithmetic you do here,select granule_size/value from v$sga_dynamic_components, v$parameter where name = 'db_block_size' and component like 'KEEP%';it shows you the number of buffers per granule, which I would not think has any meaning.I'd been looking at some different sites studying this, and what I got from that, was that this granularity gave you the minimum you could set the db_keep_cache_size, that if you tried setting it below this value, it would be bumped up to it, and also, that each bump you gave the keep_cache, would be in increments of the granularity number....?
    Thanks,
    cayenne

  • Oracle 9i Automatic PGA Memory Management

    Hello,
    my team and me, we are facing difficulties to change the size of the PGA used by our server processes for HASH JOIN, SORT... operators,
    here you can see the results of "select * from v$pgastat":
    [pgastat dynamic view results|http://pastebin.com/m210314dc]
    We have been increasing consecutively our pga_aggregate_target parameter from 1.7 Gb initially to 4Gb then at the end 6Gb, the value of "Global memory bound" and " aggregate pga auto target" on the link above are still equal to 0.
    I have been reading threads on the forum and documentation see below, I understand how the global memory manager (CKPT) computest the sql memory target and then the global memory bound, as far as I understand I can only "play" on the pga_aggregate_target value in order to increase the size of our PGAs (I exclude to play with hidden parameters).
    - Joze Senegacnik: Advanced Management of working areas in Oracle 9i/10g : http://tonguc.yilmaz.googlepages.com/JozeSenegacnik-PGAMemoryManagementvO.zip
    - Dageville Benoit and Zait Mohamed: SQL memory management in oracle 9i
    Here different information that could be usefull:
    OS: solaris 10 (db running in a non global zone)
    Arch: 64-bit sparcv9 kernel modules
    Physical memory: 32 Gb (being shared between all non global zones)
    Oracle version: 9.2.0.5 32bits
    Values of init parameters and hidden parameters that could be relevant:
    [init parameters|http://pastebin.com/m40340cf4]
    [hidden parameters|http://pastebin.com/m50d74c53]
    Maybe useful queries:
    over work areas views, I use the following script:
    [wa_analysis.sql|http://pastebin.com/d606ebd9b]
    and the result of it:
    [result of script wa_analysis.sql|http://pastebin.com/m5f49a2e5]

    Joze Senegacnik wrote:
    - either your sessions are using a lot of memory for storing variables like pl/sql arrays which is subtracted from automatic management: PGA_AGGREGATE_TARGET - (aggregated persistent area + a part of the run time area of all server processes)
    - you are hitting a bug
    - or maybe something elseI am really happy you come to this conclusion too, they are the same we made with my team and we have submitting to Oracle support via metalink SR 3-1216060641, we were asking if we hit the following bug (in note 1) or we leak about pl/sql or java... or else indeed,
    note 1: PGA_AGGREGATE_TARGET Assigned Memory Is Left Unconsumed When Set High [ID 844542.1]
    Joze Senegacnik wrote:
    I would like to know:
    1.) what were the values for global memory bound and autotarget immediately (or in short time) after the database restart or when you have increased them Just after the restart of the database and just after the change of P_A_T, we query v$pgastat immediately after and the value of global memory bound and auto target were equal to 0 byte,
    2.) If you are able to change value of PGA_AGGREGATE_TARGET (P_A_T) to 10GB what happens with global memory bound and auto traget. They should be positive at least for a short time. As this is a dynamic parameter you can change it for a short time, run queries and set it back.We plan to do this tonight, we have an "heavy" ITIL change management procedures that allow us to make changes approved by change manager and only during night maintenance window on production system, I come back to you tomorrow. But we have been increasing from 1,7Gb to 4Gb to 6Gb, each time I have been querying v$sgastat in the next 2 mins and global memory bound and auto target were equal to 0 byte.
    3.) Have you checked on the OS level how much memory are using server processes - do these numbers come along with what Oracle says. Not during problematic activities, meaning active work areas performing HASH-JOIN, SORT... operators,
    unfortunately it is a production system, even if he performs poorly, we are not allowed to try or retry the poor queries, but if it comes again I'll do it,
    during low activities, here the results paste with the scripts I used:
    [pga processes info in oracle|http://pastebin.com/f2e540062]
    I spooled the result rows of this previous script in /var/tmp/pga_processes.log then I loop over all processes pid and display pmap output anon info like this:
    h5. cat /var/tmp/pga_processes.log | awk -F' ' '{print $5}' | xargs -n 1 -i pmap -x {}| grep -v 'Addres' |egrep 'Kb' 2>&1 > /var/tmp/pga_processes_os.log
    then I merge line by line the two files with unix paste command, here the results:
    [os and oracle pga informations|http://pastebin.com/f4135c8a6]
    4.) How many server processes are running on you system in average/max and are you using just dedicated processes or also shared?in average 250, we are only using dedicated processes,
    5.) At time of low activity is the global memory bound still 0 or becomes > 0. I have been querying every 15 min during more than 24 hours low activities, it still stay to 0,
    5.) Are you experiencing paging/swapping on OS level?No, here orca figures for details:
    [free memory|http://img509.imageshack.us/img509/5897/ohuron1asd2gauge1024xfr.png]
    swap
    [pagein pageout|http://img121.imageshack.us/img121/6946/ohuron1asd2gaugepginper.png]
    [memory usage|http://img19.imageshack.us/img19/2213/ohuron1asd2gaugeppkerne.png]
    6.) Please post the result of: select * from X$QESMMSGA ;during low activities, [results X$QESMMSGA|http://pastebin.com/f61df7093]
    While you will be answering to my questions I'll try to figure out what we can do to properly diagnose the problem. As you are on 9i it is a little bit harder.I am really kind of your help, as we say in my country, "if you need tow arms one day to carry something, call me."
    --Jeremy Baumont                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Oracle 11g AMM (Automatic Memory Management)

    Hi All,
    I have a very powerful server 24 Processors with 6 cores each and 74 GB RAM for my production database. The server will host only one production database. I wanted to use AMM for this database and allocate maximum memory to Oracle by setting memory_target. By default /dev/shm is set 37 GB but I wanted to increase it least 55 GB. I know I can get this changed by my system admin but I wanted to know how much memory should leave for OS?
    Please help me on sizing this.
    Thanks,
    Arun Singh

    From MOS ID 169706.1
    Automatic Memory Management
    Starting with Oracle Database 11g, the Automatic Memory Management feature requires more shared memory (/dev/shm) and file descriptors. The shared memory should be sized to be at least the greater of MEMORY_MAX_TARGET and MEMORY_TARGET for each Oracle instance on the computer. To determine the amount of shared memory available, enter the following command: # df -k /dev/shm/
    Note: MEMORY_MAX_TARGET and MEMORY_TARGET cannot be used when LOCK_SGA is enabled or with huge pages on Linux

  • Memory Management - Why not automatic?

    I just upgraded from my old 3GS to a iPhone 5 32GB.  Really love the new hardware and look, was a worth while upgrade.  Within the first two days, I was really disapointed by the battery life I was getting.  Even in standby (overnight, while sleeping) my battery would drop 30%!  I've seen a bit of improvement since starting to manage more settings regarding notifications, location services and automated push/fetch services.  But I got interested to find out more so I got one of these battery helper apps.  I picked the highest rated one, Kingsoft's Battery Doctor.  It has helped me learn a little more regarding managing battery life.  But it's brought up one more concern for me, and that is memory (RAM) management.
    So many apps are always running in the background untill I kill them out of the "task manager" or "multitask switcher".  And I didn't notice how much RAM these were taking up.  Is this also pushing down the battery life of my device?  Why can't the phone automatically close out these apps (or provide an option in the settings) after they've been inactive for say 24/48/72-hours or so?  I have apps in there that I opened days ago, but haven't accessed since.  More then 40% of my RAM was free'd once I closed out these unused apps.
    Any recommendations?  Any chance Apple would add this recommendation to help with OS performance optimization?

    Ok, thanks.  I guess back to my first concern... any recommendations on how to improve battery life?  I've read some threads about it, just want to make sure I'm not missing anything.  I'm seeing 20-30% battery life drop when the phone is in standby overnight... I think that's crazy.  I'm expecting less then 10% when in standby overnight (since it's supposed to have 225 hours in standby).
    Bluetooth is not enabled.
    Automatic iCloud syncs are minimal (contacts, calander & find my iPhone).
    I've disabled multiple excessive Location Services, and no reason it should be running over night.
    I've highly limited the notification center items... never wanted lots of them anyway.
    I've removed/readded my Gmail account (only email setup)... not on Push, it's on Fetch.
    Should I use "Do Not Disturb" mode overnight?  Will that help?
    Thanks.

  • Oracle Automatic Memory Management

    Are there any restrictions or best practices regarding the setting of Oracle Automatic and Manual Memory Management (in particular the setting of these parameters: SGA_TARGET, SGA_MAX_SIZE, MEMORY_TARGET, MEMORY_MAX_TARGET) on various Oracle instances on the same server/node/virtual machine. In other words can the memory management schemes be mixed among various Oracle instances on the same server/node/virtual machine. For example suppose a server houses three Oracle instances - inst01, inst02, inst03. Can inst01 and inst03 use automatic memory management and inst02 use manual memory management. Are there any restrictions or best practices that should be noted? If there are multiple Oracle instances on the same server, is it a requirement that they all follow the same memory management scheme or is it a best practice to do so? Obviously, the total memory requested for the Oracle instances combined would not exceed the total physical memory available on the server.
    Note: we are currently using Oracle 11g R2 specifically 11.2.0.1 on Solaris

    sbing52 wrote:
    Are there any restrictions or best practices regarding the setting of Oracle Automatic and Manual Memory Management (in particular the setting of these parameters: SGA_TARGET, SGA_MAX_SIZE, MEMORY_TARGET, MEMORY_MAX_TARGET) on various Oracle instances on the same server/node/virtual machine. Not really or at least I am not aware of.
    In other words can the memory management schemes be mixed among various Oracle instances on the same server/node/virtual machine. Each instance is going to work individually so the answer is yes .
    For example suppose a server houses three Oracle instances - inst01, inst02, inst03. Can inst01 and inst03 use automatic memory management and inst02 use manual memory management.Yes.
    Are there any restrictions or best practices that should be noted? If there are multiple Oracle instances on the same server, is it a requirement that they all follow the same memory management scheme or is it a best practice to do so?As I said, not that I am aware of. As long as you are able to accommodate the memory requirements under your installed RAM, you should be okay.
    Obviously, the total memory requested for the Oracle instances combined would not exceed the total physical memory available on the server.Yep.
    Note: we are currently using Oracle 11g R2 specifically 11.2.0.1 on SolarisPatch to the latest patchset which is 11203.
    Aman....

  • Sort Area Size in Automatic memory management

    Hello All
    I am aware that the AREASIZE is ignored of the PGA_AGGREGATE_TARGET is set.
    So how is it possible that if we incrase the SORT_AREA_SIZE, the performance improves?
    does this necessarily mean that the PGA_AGGREGATE_TARGET was not set to a proper value that it instead used the SORT_AREA_SIZE instead?
    thanks

    Hi,
    If you have set workarea_size_policy=auto then under the automatic PGA memory management mode, sizing of work
    areas for all sessions becomes automatic and the AREASIZE parameters are
    ignored by all sessions running in that mode.
    In auto mode if you change any AREASIZE parameters will be ignored.
    If you want to manually handle ARASIZE then turnoff the Automatic pga memory by setting workarea_size_policy=MANUAL and then your changes to parameter will take effect but it's advisable to set pga to automatic.
    To check whether your pga is set proper or not check v$pga_target_advice view
    SELECT round(PGA_TARGET_FOR_ESTIMATE/1024/1024) target_mb,
    ESTD_PGA_CACHE_HIT_PERCENTAGE cache_hit_perc,
    ESTD_OVERALLOC_COUNT
    FROM V$PGA_TARGET_ADVICE;
    This will give you how your pga is set.
    chirag

  • In 11g, How to Enable Automatic Shared Memory Management (ASMM)

    hi experts,
    I have a new 11.2 g database and I want to configure it to use ASMM.
    To enable ASMM, should I assign a non-zero size to the Memory_Target parameter or the SGA_Target ? I have read conflicting statements.
    Thanks, John

    If you mean Automatic Memory Management, pl see
    http://download.oracle.com/docs/cd/E11882_01/server.112/e10595/memory003.htm#ADMIN11011
    http://download.oracle.com/docs/cd/E11882_01/server.112/e10897/instance.htm#ADMQS12039
    HTH
    Srini

  • Confusion about Automatic Shared Memory Management

    Hi,
    Oracle Database 10g includes the Automatic Shared Memory Management feature which simplifies the SGA memory management significantly. To use Automatic Shared Memory Management, we have to set the SGA_TARGET initialization parameter to a nonzero value and the STATISTICS_LEVEL initialization parameter to TYPICAL or ALL.
    Oracle Database 10g Rel. 2 documentation, in some places, says that:
    If SGA_TARGET is specified, then the following FIVE memory pools are automatically sized:
    * Buffer cache (DB_CACHE_SIZE)
    * Shared pool (SHARED_POOL_SIZE)
    * Large pool (LARGE_POOL_SIZE)
    * Java pool (JAVA_POOL_SIZE)
    * Streams pool (STREAMS_POOL_SIZE)
    Ref.:
    1. http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14237/initparams192.htm
    2. http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14220/memory.htm
    3. Oracle Database 10g: New Features for Administrators - Student Guide
    But in some places I found the following:
    If SGA_TARGET is specified, then the buffer cache (DB_CACHE_SIZE), Java pool (JAVA_POOL_SIZE), large pool (LARGE_POOL_SIZE), and shared pool (SHARED_POOL_SIZE) memory pools are automatically sized.
    Here you can see that Streams Pool is not included in the automatically sized pools.
    Ref.:
    1. http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14211/build_db.htm#sthref252
    Also, according to Oracle Press' Book "OCP Oracle Database 10g: New Features for Administrators Exam Guide:
    Under Automatic Shared Memory Management, the database manages the
    following FOUR major components of the SGA, also known as the auto-tuned SGA
    parameters:
    ■ Buffer cache (DB_CACHE_SIZE)
    ■ Shared pool (SHARED_POOL_SIZE)
    ■ Large pool (LARGE_POOL_SIZE)
    ■ Java pool (JAVA_POOL_SIZE)
    It is important to understand that even under Automatic Shared Memory
    Management, you still need to configure any SGA component other than the four
    auto-tuned components. Following are the manually sized components of the SGA:
    ■ Redo Log Buffer
    ■ The KEEP and RECYCLE buffer caches (if specified)
    ■ The nonstandard block size buffer caches (if specified)
    ■ The new Streams pool SGA component
    ■ The new Oracle Storage Management (OSM) buffer cache, which is meant
    for the optional ASM instance
    Now my question is "IS Streams Pool an auto-tuned SGA parameter?"
    Thanks in advance.
    --Khan.

    Hi,
    I would advise you to read Document I.D. Note:295626.1 on Oracle Metalink.
    It states that
    When enabled, it lets Oracle decide of the right size for some components of the SGA:
    SHARED POOL
    LARGE POOL
    JAVA POOL
    DB CACHE (using the DB_BLOCK_SIZE value)
    The SGA_TARGET value will therefore define the memory size sharable between auto-tuned and manual parameters.
    The manual parameters are:
    DB_<KEEP/RECYCLE>CACHESIZE
    DB_nK_CACHE_SIZE (non default block size)
    LOG_BUFFER
    FIXED SGA
    STREAMS_POOL_SIZE
    Adith

  • Question about 11gR2 Grid, RAC, /dev/shm and Automatic Memory Management

    Hello,
    i've recently installed grid and rdbms software 11.2.0.2 on a two node Oracle Linux cluster with 128gb ram each node.
    I'm using ASM to store data and ocr and I'm testing Automatic Memory Management.
    When I finished Grid+RDBMS installation I've seen that /dev/shm size is 64gb (half of my total RAM).
    I've created a database with dbca and when I was asked to choose if I wanted to use AMM I've noticed that I could
    allocate only about 60gb for Oracle. If I chose more than 90gb I got an error saying:
    Using Automatic Memory Management requires 60gb available in my two nodes.
    The current available space in the two nodes is only 30gb and 30gb.
    If you want to use AMM you should either free up some space in /dev/shm
    or reduce the memory allocated to Oracle
    I was wondering when (during the installation or the settings of kernel parameters) did I define the space of /dev/shm ?
    Since I have 128gb of RAM wouldn't it be better to use more than 64gb of ram for my /dev/shm tmpfs partition ?
    Is there a limit or a ratio for best practice for my RAM and the /dev/shm ?
    thanks in advance.

    user9051299 wrote:
    Is the "half of the RAM size" a kernel's default value or Oracle's ? Neither. There are a number of unique factors that determine the best memory size and fit for Oracle - including just how much memory is effectively available (i.e. how much is needed for other services and processes).
    And from what I understand i don't "break" any Oracle's best practice by increasing the /dev/shm right ?Correct. (at least none that I'm aware of, and none that I have read in Oracle's RAC Starter Kit documentation).

  • Large SGA On Linux and Automatic Shared Memory Management problem

    Hello
    I use Oracle10gR2 in linux 32bit and I use http://www.oracle-base.com/articles/linux/LargeSGAOnLinux.php manual
    for larger SGA it works fine but when I set sga_target parameter for using Automatic Shared Memory Management
    I recieve this error
    ERROR at line 1:
    ORA-02097: parameter cannot be modified because specified value is invalid
    ORA-00824: cannot set sga_target due to existing internal settings, see alert
    log for more information
    and in alert log it has been wrote
    Cannot set sga_target with db_block_buffers set
    my question is when using db_block_buffers can't use Automatic Shared Memory Management ?
    Is any solution for using both Large SGA and Automatic Shared Memory Management ?
    thanks
    Edited by: TakhteJamshid on Feb 14, 2009 3:39 AM

    TakhteJamshid wrote:
    Do it means that when we use large SGA using Automatic Shared Memory Management is impossible ?Yes its true. An attempt to do so will result inthis,
    >
    ORA-00825: cannot set DB_BLOCK_BUFFERS if SGA_TARGET or MEMORY_TARGET is set
    Cause: SGA_TARGET or MEMORY_TARGET set with DB_BLOCK_BUFFERS set.
    Action: Do not set SGA_TARGET, MEMORY_TARGET or use new cache parameters, and do not use DB_BLOCK_BUFFERS which is an old cache parameter.>
    HTH
    Aman....

  • Managing memory Automatic Memory Management

    Hello all,
    Can any one give me the difference between MEMORY TARGET and MEMORY AGGREGATE TARGET?
    Thanks

    user9362044 wrote:
    Hello all,
    Can any one give me the difference between MEMORY TARGET and MEMORY AGGREGATE TARGET?
    ThanksThere is no MEMORY AGGREGATE TARGET parameter but there is MEMORY_TARGET parameter which indicate Automatic Memory .

  • Automatic PGA Memory Management in 9i and 10g

    Hi,
    I read the Doc# 223730.1 for Auto PGA advisory.
    At one point in the document, there is given a query to calculate percentage of times work areas were executed in optimal, one-pass, or multi-pass mode since start-up.
    My question is why there is a clause low_optimal_size > 64*1024); ---- for 64 K optimal size
    Why it is safe to ignore all the workareas below 64 K.
    How to decide which entries should be ignored?
    Thanks,
    Neeraj

    I think 64K value used in that document is just an example.
    You can use the prior query (one above which you have cited here) for finding non-empty buckets and then view histograms for range of your concern (the range which is getting used more frequently in your environment).

  • Working on Automatic Memory Management

    Can any one understand this error message on startup and how to solve this?
    I am working on 11g server Linux 5.2 OS.
    Thanks
    Alain
    SQL> ALTER SYSTEM SET SGA_MAX_SIZE=2200M SCOPE=SPFILE;
    System altered.
    I try to bounce the database for the change of my SGA_MAX_SIZE became effective
    SQL> SHUTDOWN IMMEDIATE
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    SQL> STARTUP
    ORA-00843: Parameter not taking MEMORY_MAX_TARGET into account, see alert log for more information

    00843, 00000, "Parameter not taking MEMORY_MAX_TARGET into account"
    // *Cause: The parameter was larger than MEMORY_MAX_TARGET.
    // *Action: Check the other error messages for additional information about the parameter. Set the parameter to a lower value than MEMORY_MAX_TARGET.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Java Memory Management/Out of Memory

    Hi Guys,
    I have a few questions about java memory management
    Because i keep encounter a lot of out of memory error which i think java does not handle Vector/ArrayList re initialisation automatically
    Asumme i have 2 million record in database and , i will process every 80000 and store it in Vector
    while(true)
    list = new Vector();
    list = GetResultFromDatabase() // Process Every 80000
    if list.size() > 0 =======> My VEctor list contain 80000
    //loop the 800000
    //Process Some logic and data
    list.clear();
    list = null;
    If u See , i need to call list.clear and list = Null every process so it wont cause me out of memory
    Before i put that 2 lines , i always hit out of memory Exception.
    Seems like garbage collector cannot claim memory if i dont declare
    Is Memory Occupied by VEctor cannot be recoverable if we dont explitcitynya clear it and set it to NULL??
    Because in term of logic wise it wont cause a problem if i just
    do in this statement after it process like below
    list = new Vector() which will reinstatiate the object.
    Thanks.

    Damm i should hacve read your post again
    Look here:
    while(true)
    list = new Vector();What uer doing is craeting a new vector object everytime the while does an ityteration so when your while loop does 40000 loops there will be 40000 new objects in jou memory
    i sugest moving the decleration outside the while loop:
      list = new Vector();
    while(true)
    ///rest of loop
    } This could also be a problem
    hope it help :-)
    werns

Maybe you are looking for

  • Error opening a Microsoft Project 2007 file

    I am receiving an error when trying to open a Project 2007 file.  There is no error code.  The error says "The operation cannot be completed because the source file contains invalid project data or the total number of rows would exceed the limit of 1

  • Hey Baby-boomer! You out there?

    This here is Shrimperchuck back to ya. O-Kay, I had to get a replacedment 2gig chip set which seems to work fine=after having to re-boot from scratch&%^$%%! Got what I could backed up to DVD, Now I can't seem to get my back-ups to reinstall corectly?

  • Doubt in classical report

    hi,         how to increase the font size in the output of classical report.. Gowri

  • Best settings for t1i 720 clips in Final cut

    Hello Everyone, I am sorry to bug you with this question but will so appreciate it if someone can shed some light on my neck of the woods. I am shooting a small project using Canon's T1i. Beautiful HD videos but after I followed a colleague's advice

  • XML class generator error

    Hi all: I've download the XDK and I got the error when I try to run the demo by typing following command xmlcg -d CG.dtd sample.xml "Failed to initialize parser, code 201" Any help will be very appreciated Regards Ivan Chung