[Oracle]-[LRU and DBWR]-LRU Algorithm and Application in DBWR

Source: Internet
Author: User

[Oracle]-[LRU and DBWR]-LRU algorithm and Applications in DBWR the Oracle architecture often see LRU algorithm, Least Recently Used, this is also called the "least recently used page replacement algorithm". In short, Oracle will remove databases that are not used in memory recently from the memory to free up space for loading additional data. Although the implementation of algorithms cannot be obtained, it is not necessary for many of us to understand them. It is more important to know its role and analyze and judge some problems based on it. There is an ideal Calculation for this algorithm, that is, each swap out of the memory will be used at the latest in all memory, and the swap can be postponed to the maximum extent, however, this algorithm is ideal for memory replacement and cannot be implemented. In order to reduce the gap with the ideal algorithm, various exquisite algorithms have emerged. LRU is one of them.

It is based on: the data in the previous memory is likely to be frequently used later. In other words, the data in the memory that has been useless for a long time may not be used in the future, this is a well-known principle of locality. It runs based on the same principle and is faster than the memory speed. Therefore, we only need to find the least recently used memory data to call up the memory every time we change the memory, which is the content of the LRU algorithm. As mentioned in some books, "If the database is transferred by air, eventually DBWR will write all the buffer areas to the disk", DBWR will write the dirty buffer to the disk, using the LRU algorithm, as described above, based on several conditions triggered by DBWR, And the LRU algorithm, DBWR will write all buffer caches to the disk.

Related Article

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.