What Does oracle do when executing commit?

Source: Internet
Author: User

What Does oracle do when executing commit? COMMIT is a very fast operation. When we release the commit command, the really difficult action has been completed and the data changes have been executed in the database, therefore, 99% of the tasks have been completed. Www.2cto.com For example: The following operations have been generated: 1. the undo block has been generated in the SGA (Buffer Cache); 2. A changed data block and index block have been generated in the SGA (Buffer Cache). 3. the REDO information of the first two items is generated in the redo log buffer; 4. depending on the data size produced by the first three items and the time required for the operation, some data in the buffer may have been exported to the disk; 5. all required locks have been obtained. When the COMMIT command is executed, only the following operations are performed: 1. the SCN: SCN generated for the transaction is a type of timing information of the ORACLE database. It is used to ensure the transaction sequence, Failure Recovery, and read consistency and check points of the database, at any time, 1 is automatically added to the SCN; 2. write the redo information related to the transaction that is not written to the redo log file from the redo log buffer to the redo log file. This is the actual COMMIT. This step is completed, indicating that we have completed the operation. COMMIT: the TRANSACTION is removed from V $ TRANSACTION. The sessions recorded in 3.V$ LOCK about the TRANSACTION are released, and other transactions requiring these locks are awakened. 4. execute block cleanup to clear the transaction information stored in the block header.

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.