Data block buffers

the output is from our database which ver 8.0.3
can anybody please explain the concept, what is the problem with my data block buffers.
Determine if the data block buffers is set high enough:
SQL> select 1-(sum(decode(name, 'physical reads', value,0))/
2 (sum(decode(name, 'db block gets', value,0)) +
3 (sum(decode(name, 'consistent gets', value,0))))) * 100
4 "Read Hit Ratio"
5 from v$sysstat;
Read Hit Ratio
-18.095581

In General way the Buffe Cache Hit Ratio must be high for a good performance. As I guess you know : the buffer cache is where is stored temporaly copy of data blocks. Example: if you amke a select of a table which is not in the buffer Cache those blocks must me loaded from the datafiles because they are needed. If you apply the query again those blocks are going to be in memory ( Buffer Cache ). To tune the Buffer Cache you have to consider not only the values of the parameters related but rather you have to consider to Cache the tables that are retrieved through full scans with a lot of frequency.
Joel Pérez
http://otn.oracle.com/experts

Similar Messages

  • ORA-00607: Internal error occurred while making a change to a data block

    hi
    i hv use testing purpose oracle 10 Xe in unix
    but when today i hv connect database following error occured
    SQL> startup
    ORACLE instance started.
    Total System Global Area 83886080 bytes
    Fixed Size 1257284 bytes
    Variable Size 75497660 bytes
    Database Buffers 4194304 bytes
    Redo Buffers 2936832 bytes
    Database mounted.
    ORA-00607: Internal error occurred while making a change to a data block
    ORA-00600: internal error code, arguments: [4193], [625], [640], [], [], [],
    I hv check alert log , but no proper solution is given , how can start database

    Duh, and of course I missed the significance of
    oracle 10 Xe in unix
    XE is only supported for Linux - according to the downloads page that means "Debian, Mandriva, Novell, Red Hat and Ubuntu".
    Oracle have not publically stated the reasons why XE is only available on Linux and Windows, but my guess is that it is something to do the Intel chip architecture. If this is so it would be possible for Oracle to port XE to run on Solaris for x86. But they have not done so yet.
    Which means, alas, that you are unlikely to get any help for this one, because XE is not supported on any unix platform.
    Good luck, APC

  • Relationship between a data block and latch

    Hello Experts,
    I have just read an article about indexes and full table scan by Richard Foote. http://richardfoote.wordpress.com/2009/04/16/indexes-on-small-tables-part-i-one-of-the-few/
    I thought each block required only one latch for each operation. However, I don't undersand that why a single block required 2 latch? The qoute is the following,
    Note that yes indeed, there were 4 consistent gets performed and that none of the consistent gets were the “cheaper” consistent gets examinations. Therefore, the 4 consistent gets used in performing the FTS of the one block table required 4 x 2 = 8 latches.
    Can anyone explain the above quote please?
    Thanks in advance.

    Jonathan Lewis wrote:
    Solomon Yakobson wrote:
    Read Concepts manual. Database Buffer Cache in particular:Every buffer has an access mode: pinned or free (unpinned).
    I hope the manual doesn't use the word "free" as a synonym for "unpinned", since a buffer (header) with state = "free" is one that doesn't hold a copy of a datablock and is therefore immediately available for re-use.
    Regards
    Jonathan Lewis
    Hello Sir,
    I have just read Memory Architecture document, buffer states part, I know the meaning of dirty buffers. However, when we just SELECT any table, the corresponding data blocks that read into memory from disk, are they considered as clean buffers? Because as far as I understand from dirty buffers, these are modified buffers. And maybe the manual should have used "clean" instead of "free"?
    The database uses a sophisticated algorithm to make buffer access efficient. Pointers to dirty and nondirty buffers exist on the same least recently used (LRU) list, which has a hot end and cold end. A coldbuffer is one that has not been recently used. A hot buffer is frequently accessed and has been recently used
    Also the above statement is excerpt from Oracle Memory Architecture document, does the nondirty buffers refer to data blocks that move to the memory in SELECT query?
    Thanks a lot for your remarkable thoughts.

  • FRM-92101 when scrolling through a data block on a form

    Folks,
    We recently converted a Forms 6i application to Forms 10g (re-compiled, little changes were requested). Running against an Oracle 10g database (10.1.2.3) on a Solaris server.
    When users scroll through the data block on a canavas after about 2 or 3 screens t hy get the wonderful error message FRM-92101, talking about an error in the Forms Server at startup... (Kinda silly since it is AFTER the Form has started running, but beyond the point).
    I have tried adjusting the # of rows buffered for datablock (started out at 0, changed to 25, 50, 100) and rows to display at once to 1, 10, 16 and we still keep getting this error.
    Can anybody suggest an solution or point me in the right direction to solve this issue?
    Thank you,
    Tony Miller| Consultant | MRE Consulting, Ltd.
    3333 Richmond | Suite 300 | Houston, Texas 77098 [email protected] | 713-844-6211 Consulting | Infrastructure | Outsourcing | Staffing

    Tony,
    I don't have your correct email address. Drop me a line at [email protected]
    Thanks,
    Monty

  • ORA-01578: ORACLE data block corrupted on tables in sysaux tablespace

    Dear Experts,
    From the alert log file we noticed data block corruptions on one of our datafiles. After further investigation, we realized that the corruptions were on 3 of the AWR related tables in the SYSAUX tablespace:
    1. WRH$_LIBRARYCACHE
    2. WRH$_TEMPSTATXS
    3. WRI$_ALERT_OUTSTANDING
    The bad news is that we may not have a valid rman backup to do the recovery due to the retention policy - RECOVERY WINDOW OF 2 DAYS. Since this is a development database with limited monitoring, we did not discover the corruption until 6 days later. The issue happened about 6 days ago (about Christmas time).
    So, what are our recovery options? Can someone advice? We are thinking about drop and recreate the 3 affected v$WR* tables, but not quite sure about the impact to the system if we drop and recreate the 3 objects. Did someone experience this type of recovery. If you did, what are your approaches?
    We are running oracle 10.2.0.3 version.
    I greatly appreciate your input and suggestion. Thanks!!!

    as long as you have a backup of ur database before christmas, you can use the " MAXDAYS " cmd to get ur backup working so long as you have not used delete obsolote....had a same sistuation....where i had a backup and trying to restore it ...kept saying no valid backup...after going thru some stuff...found the MAXDAYS cmd to use my backup...here is an example ...
    $ rman target /
    Recovery Manager: Release 10.2.0.2.0 - Production on Sun Apr 6 09:05:44 2008
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    connected to target database (not started)
    RMAN> SET DBID=1528894801
    executing command: SET DBID
    RMAN> startup force nomount;
    startup failed: ORA-01078: failure in processing system parameters
    LRM-00109: could not open parameter file '/u01/app/oracle/product/10.2.0/db_1/dbs/initsameera.ora'
    starting Oracle instance without parameter file for retrival of spfile
    Oracle instance started
    Total System Global Area 159383552 bytes
    Fixed Size 1259672 bytes
    Variable Size 58722152 bytes
    Database Buffers 92274688 bytes
    Redo Buffers 7127040 bytes
    RMAN> set controlfile autobackup format for device type disk to '/u99/backup/sameera/control_spfile_%F';
    executing command: SET CONTROLFILE AUTOBACKUP FORMAT
    using target database control file instead of recovery catalog
    RMAN> run
    2> {
    3> allocate channel p1 type disk;
    4> restore spfile to pfile '/u01/app/oracle/product/10.2.0/db_1/dbs/initsameera.ora' from autobackup;
    5> shutdown abort;
    6> }
    allocated channel: p1
    channel p1: sid=36 devtype=DISK
    Starting restore at 06-APR-08
    channel p1: looking for autobackup on day: 20080406
    channel p1: looking for autobackup on day: 20080405
    channel p1: looking for autobackup on day: 20080404
    channel p1: looking for autobackup on day: 20080403
    channel p1: looking for autobackup on day: 20080402
    channel p1: looking for autobackup on day: 20080401
    channel p1: looking for autobackup on day: 20080331
    channel p1: no autobackup in 7 days found
    released channel: p1
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of restore command at 04/06/2008 09:09:09
    RMAN-06172: no autobackup found or specified handle is not a valid copy or piece
    Solution:
    RMAN> shutdown abort;
    RMAN> EXIT;
    $ ps -ef |grep pmon
    oracle 2891 2856 0 09:05 pts/1 00:00:00 grep pmon
    oracle 7448 1 0 Apr05 ? 00:00:00 ora_pmon_primary
    $export ORACLE_SID=sameera
    $ rman target /
    Recovery Manager: Release 10.2.0.2.0 - Production on Sun Apr 6 09:05:44 2008
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    connected to target database (not started)
    RMAN> SET DBID=1528894801
    executing command: SET DBID
    RMAN> startup force nomount;
    startup failed: ORA-01078: failure in processing system parameters
    LRM-00109: could not open parameter file '/u01/app/oracle/product/10.2.0/db_1/db s/initsameera.ora'
    starting Oracle instance without parameter file for retrival of spfile
    Oracle instance started
    Total System Global Area 159383552 bytes
    Fixed Size 1259672 bytes
    Variable Size 58722152 bytes
    Database Buffers 92274688 bytes
    Redo Buffers 7127040 bytes
    RMAN> set controlfile autobackup format for device type disk to '/u99/backup/sameera/control_spfile_%F';
    executing command: SET CONTROLFILE AUTOBACKUP FORMAT
    using target database control file instead of recovery catalog
    RMAN> run
    2> {
    3> allocate channel p1 type disk;
    4> restore spfile to pfile '/u01/app/oracle/product/10.2.0/db_1/dbs/initsameera.ora' from autobackup maxdays 15;
    5> shutdown abort;
    6> }
    released channel: ORA_DISK_1
    allocated channel: p1
    channel p1: sid=36 devtype=DISK
    Starting restore at 06-APR-08
    channel p1: looking for autobackup on day: 20080406
    channel p1: looking for autobackup on day: 20080405
    channel p1: looking for autobackup on day: 20080404
    channel p1: looking for autobackup on day: 20080403
    channel p1: looking for autobackup on day: 20080402
    channel p1: looking for autobackup on day: 20080401
    channel p1: looking for autobackup on day: 20080331
    channel p1: looking for autobackup on day: 20080330
    channel p1: looking for autobackup on day: 20080329
    channel p1: looking for autobackup on day: 20080328
    channel p1: looking for autobackup on day: 20080327
    channel p1: looking for autobackup on day: 20080326
    channel p1: looking for autobackup on day: 20080325
    channel p1: looking for autobackup on day: 20080324
    channel p1: looking for autobackup on day: 20080323
    channel p1: autobackup found: /u99/backup/sameera/control_spfile_c-1528894801-20080323-00
    channel p1: SPFILE restore from autobackup complete
    Finished restore at 06-APR-08
    Oracle instance shut down
    Check to make sure if initsameera.ora exists in $ORACLE_HOME/dbs location.
    $ cd $ORACLE_HOME/dbs
    $ ls -ltr
    total 7052
    -rw-r----- 1 oracle oinstall 2560 Apr 5 13:21 spfileprimary.ora
    -rw-r----- 1 oracle oinstall 7061504 Apr 5 13:23 snapcf_primary.f
    -rw-rw---- 1 oracle oinstall 1544 Apr 5 18:42 hc_sameera.dat
    -rw-r--r-- 1 oracle oinstall 1087 Apr 6 09:12 initsameera.ora
    $ pwd
    /u01/app/oracle/product/10.2.0/db_1/dbs
    $

  • Aligning data blocks relative to disk sectors

    Hi
    I Have a huge 20GB file that stores a lot of small data structures typically between 200 bytes and 20 kb. There are many millions of these small data blocks that are all stored together in a single file. I can read each data structure from a file channel by specifying the offset of the data structure in the file.
    I need to read thousands of these small data structures every second. To help with this I'm using a solid state disk as the reads will be mostly random. However I can improve performance by aligning my data structures with respect to the disk sectors. The disk sector size is 4096 bytes. If I don't align them then I end up with the smaller data structures straddling two sectors in most cases. This means that performing a read on a 3KB data structure that straddles two sectors will incur a read of 8KB instead of 4KB which will hurt read performance.
    What I cant figure out is how to tell where the sectors begin and end. The file channel API only gives offsets relative to the file not relative to the disk. My intuition tells me that if I knew exactly what the offset of the start of the file was relative to the disk I could work out where each sector is relative to my file and write the data structures to the disk taking this information into account, but I don't know how to do this.
    I know many databases do this with their internal pages but I haven't seen anyone do it in Java so far.
    Anybody else tried to do this I Java?
    Edited by: fireandspike on May 22, 2010 3:53 PM

    Colby_ wrote:
    dannyyates wrote:
    Fragmentation has very little performance impact on SSDsAbout as much as worrying about reading from just one sector ;pOn the contrary. If I want to read (or write) one sector's worth of data and I don't do it at the sector boundary, the disk is going to have to perform two I/O ops, potentially with a seek in between. The seek is (almost) meaningless in the SSD example - and hence fragmentation in general is meaningless - but it certainly isn't meaningless on an HDD. However, having to read two sectors is NOT meaningless in either case. You have just immediately halved your potential throughput.
    We do a very similar thing on a project I'm working on at the moment. We need maximum write performance to disk to journal changes to the system and we get much, much better performance by making sure that we write in a way which is sympathetic to the underlying hardware - specifically, buffering 4k of data and then writing exactly 4k (including trailing zeros if the last thing won't fit in the 4k buffer) to the disk in a single hit. In this way, we minimise JNI transitions (which are horribly slow and introduce huge latency spikes) and we give the disk the maximum chance of keeping up with us because it never has to re-read and update a sector to add data to it and can practically stream the data straight to the platter.

  • Continously changing data blocks

    Hi
    If the data blocks in the buffer continously get updated such that they never reach the Least used list of LRU,then when will they be written to disk?

    To ensure that DBWR writes all modified buffers any of the following is adequate :
    1. SHUTDOWN (NORMAL or IMMEDIATE)
    2. ALTER DATABASE BEGIN BACKUP
    3. ALTER SYSTEM CHECKPOINT
    4. ALTER SYSTEM SWITCH LOGFILE -- DBWR writes modified buffers "lazily", so the command is returned even before all modified buffers are written to disk
    5. ALTER TABLESPACE tbsname BEGIN BACKUP -- only the Tablespace is checkpointed, not the whole instance
    6. DROP or TRUNCATE table -- only the table's (and indexes) buffers are checkpointed
    7. Segment checkpoint issued by a Parallel Query -- only the segment's buffers are checkpointed
    8. Segment checkpoint initiated by direct path serial read implemented in 11g -- only the segment's buffers are checkpointed (see URL added by Joel (jgarry) in later comments)
    Hemant K Chitale
    Edited by: Hemant K Chitale on Jan 11, 2011 11:13 AM

  • Data blocks in forms 6i, can not see the data

    i have built an application in forms with some data blocks. the blocks a connect to some tables in the db. i have built them connectd as "system". but when i run the applicatio as user x i can do select, insert, update, delete, but i can not se the records in the datablocks (they are empty), but i can do all transactios. why?

    First of all, developing from the System schema is not a good idea.
    Who owns the tables your form is connecting to? The table owner should create a public synonym for each table name, and also needs to grant user x access to the table.

  • I can not put the data of a field(LONG RAW) consulted into a item of a data block

    I want to query a field that is LONG RAW(it's a image) and put the data into a item of a data block (in Forms Builder), when i write ":BLOCK.FOTO:=vfoto" i recieve this errors: "bad bind variable ....". How can i put the data of field of my DB and put the data in a item of a data block(in Forms Builder)?.
    I can store a image in a table of my DB, but i want to query a image stored in my DB and put it into anothers table, all this on FORMS BUILDER.

    You have to base the image item on a base table and use EXECUTE_QUERY on that block. You can't do a direct select in PL/SQL into the item

  • Insert and update a data block which is based on view--urgent help required

    Hi experts,
    I created a view(A_VIEW) which is based on a union select. I have created a data block A_VIW_BLOCK which is based on this view. I need to insert/update one of the base tablesfor A_VIEW through this data block. I also need to be able to make a query through all the fields in the view.
    The questions are:
    1.Can it be done at all?
    2. What properties need to be set?
    3. If can't be done, what the best approach to achieve this?
    Thanks in advance!!
    Michael

    hi
    try something like this.
    CREATE TABLE demo_tab (
    person_id NUMBER(3),
    first_name VARCHAR2(20),
    last_name VARCHAR2(20));
    CREATE OR REPLACE VIEW upd_view AS
    SELECT * FROM demo_tab;
    INSERT INTO demo_tab
    (person_id, first_name, last_name)
    VALUES
    (1, 'Daniel', 'Morgan');
    INSERT INTO demo_tab
    (person_id, first_name, last_name)
    VALUES
    (2, 'Helen', 'Lofstrom');
    COMMIT;
    SELECT * FROM upd_view;
    UPDATE upd_view
    SET person_id = person_id * 10;
    SELECT * FROM upd_view;
    desc user_updatable_columns
    SELECT table_name, column_name, updatable, insertable, deletable
    FROM user_updatable_columns
    WHERE table_name IN (
       SELECT view_name
       FROM user_views);
    SQL> create table dummy (f1 number);
    Table created.
    SQL> create view dummy_v 
    2  as 
    3  select f1 from dummy 
    4  union all  
    5  select f1 from dummy;
    View created.
    SQL> create trigger dummy_v_it 
    2  instead of insert 
    3  on dummy_v 
    4  for each row 
    5  begin 
    6    insert into dummy values (:NEW.f1); 
    7  end; 
    8  /
    Trigger created.
    SQL> insert into dummy_v values (1);
    1 row created.
    SQL> select * from dummy_v;       
    F1
    1        
    1
    SQL> select *
      2  from user_updatable_columns
      3  where table_name = 'DUMMY_V';
    OWNER    TABLE_NAME   COLUMN_NAME  UPD INS DEL
    FORBESC  DUMMY_V      F1            NO  NO  NOforms settings.
    Enforce Primary Key - No
    Query Allowed - Yes
    Query datasource Name - V_TSFDETAIL
    Insert Allowed - Yes
    Update Allowed - Yes
    Delete Allowed - Yes
    Locking Mode - Automatic
    Key Mode - Automatic
    do not forget to create synonyms.
    hope this helps.
    sarah

  • Multiple data blocks on the same canvas

    Forms newbie question:
    Is it possible to have 2 data blocks with two different sets of transactional triggers (ON-UPDATE, ON-LOCK, etc.) on the same canvas?
    I've got an example where i've got two data blocks (one sourced from a view, and one that is a CTL block) on the same canvas. The block sourced from the view is working fine. When I make updates, they are reflected, etc. But, i've got one field in the control block that I need to update from as well, and I can't seem to get it (or any of the CTL block items) to show up as "updateable", regardless of the set_item_property....theyre always grayed out.
    Do i need to take the user to a new canvas to be able to utilize the update of the ctl field?

    A second canvas is not needed. Normally, control-block items are always updateable, so there is something going on in your form to prevent it.
    > I can't seem to get it (or any of the CTL block items) to show up as "updateable",
    regardless of the set_item_property....theyre always grayed out.
    What... Is there code someplace in the form that sets them to Enabled, false? If that is the case, then to get them working again, besides setting Enabled to true, you also must set Updateable and Navigable to Property_True. (This is documented at the end of the on-line help on Set_Item_Property.)

  • Oracle Forms - How can I create a Data Block with query

    Dear friends I have a question, I couldn't do this..
    I have a sql query, I want to show the datas of the query.. How can I do this. ?
    Data Block Wizard wants a table, view or stored procedure, but I have a query, how can I create a data block with my query.. I m waiting your helps..? Please...
    Semih

    Hi,
    You have two options
    1. create a view and base the block on the view
    2. create a block with a query Data Source Type of 'FROM clause query'
    Hope this helps
    Neil

  • Multiple Selection from a data block

    Hello,
    I have a data block returning the names and surnames of employees. Can I select multiple rows from that data block?
    Thank you

    You could put a checkbox on the row and if it is ticked then interpret this as a selected row.
    Sometimes it is useful to store this type of selection in some type of structure like a record group or index by table and process those rows rather than read the data block

  • How to call two data blocks at a time.

    hi all
    i want to call two data blocks at a time on function when button pressed.
    how can I it?
    many thanks

    Many thanks that you people reply,
    I am working in oracle form developer 6i and database 10g.
    I have a form that have three data blocks,
    first block have text boxes and search button,and next two blocks display records on the basis of search criteria that is inserted in the first block and when is clicked on save button.
    the data that is to b displayed is from two different tables.
    i used Go_block('my_block')
    and call other block with the same method.
    kindly guide me how can i do it.
    Thanks in advance

  • Manipulating data from a ref cursor in the data block of a form

    I am using Oracle Forms 10g. I have a ref cursor which returns columns A, B, C, D, E where B, C, D, E are values. The "Query Data Source Name" attribute in the datablock contains "CCTR_Extract_pkg.cctr_refcur". The "Column Name" attribute of item A contains "A", item B contains "B", etc. All of these columns are displayed on the form and it all works perfectly.
    I have a new request, the users would like a 6th column displayed - column F - where it equals D - B.
    Is there any way of doing this in the form only or do I need to change the ref cursor to accomodate the new column and then the form?
    If it can be achieved in the Form (only) - then how do I reference the 2 columns?
    Thanks in anticipation
    Michael
    Edited by: user8897365 on 24-Aug-2011 10:32

    Is there any way of doing this in the form only or do I need to change the ref cursor to accomodate the new column and then the form? The REF_CURSOR is the data source of your block so you will have to modify the CCTR_Extract_pkg package and cctr_refcur REF_CURSOR.
    If it can be achieved in the Form (only) - then how do I reference the 2 columns?After you have modified your database package, I recommend you run the Data Block Wizard on your block and let Forms detect the 2 new columns. You can do this manually, but it is safer to let Forms do it for you. If you want to do it manually, open the Query Data Source Columns property and add your new columns.
    Hope this helps,
    Craig B-)
    If someone's response is helpful or correct, please mark it accordingly.

Maybe you are looking for