Db block gets explanation

Source: Internet
Author: User

 

 

Logic io (logical reads) = db block gets + consistent gets

 

Consistent get: the speed of read in consistent read mode, including the speed of read from the rollback segment.
Db block Gets: The number of reads in the current read mode, which is relatively small and special. For example, the data dictionary data is obtained. In DML, the current read mode is used to change or delete data.

 

Consistent gets: Number of select reads without for update
Db block Gets: The number of reads by update/delete/select for update.

 

Consistent gets: consistent_gets is the forward (or read consistent image) read from the rollback segment. The data you see is the start time of the query, therefore, if the block changes after the query starts, before image must be generated and the data must be read. This is the meaning of consistent read.
A query is a consistent gets (query mode). To ensure the consistency of the time point of the obtained data, a query is called consistent read, even the data obtained from the current buffer, it is also called consistent gets, which only expresses a kind of expectation of a mode. It does not mean that the bufore image generated is actually obtained from the current buffer or from the rollback segment.

 

Db block gets: Current Mode, no matter whether the data on this block may have before image, that is, whether or not the data in rollback can be rolled back, only the data of the latest block can be seen, even if others are updating, they will also see the updated status data of others. For example, when DML is used, they do not need to see the data before others change, but the data being changed. Of course, at the same time, if the operation is the same, the data is locked. That is to say, the data seen in a query may not be at the same time point, for example, a large DML. When DML starts updating a very large table, there is a process that updates a record at the end of the table, and the large update will be blocked when it reaches the record. If the process is committed, A large update will overwrite the updates of the transaction. That is to say, the data seen by this large update is current and does not have time point consistency. Therefore, it is called the current mode, I personally think that the word DB BLOCK gets is not used well and is easy to misunderstand. if it is changed to inconsistent gets, it may be more accurate.
 

Consistent gets
Db block gets + consistent gets = logical io (as opposed to physical Io). Consistent gets are current mode gets. This might entail a reconstruction of the block with the Undo (rollback) mechanism.

Number of times a consistent read was requested for a block.

 

Db block gets
Db block gets + consistent gets = logical io (as opposed to physical Io ). db block gets are current mode gets, blocks that are read as they are (even if these are being modified by another session)

Number of times a current block was requested.

 

 

Remember, we used to go around and get confused.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.