exp CONSISTENT=Y 原理:export前發出SET TRANSACTION READ ONLY命令

tolywang發表於2015-02-11
今天才知道, exp CONSISTENT=Y 之所以能保持資料一致性,原來是在export前發出SET TRANSACTION READ ONLY命令,用來保持資料在同一個時間點。 


metalink Note:113450.1

PURPOSE OF CONSISTENT=Y EXPORT
------------------------------

Export extracts data by issuing a series of SELECT statements and the snapshot time of each table's data corresponds to when the SELECT statement was issued for that table. If there is no database activity, then this is not an issue. 
However, it is possible to manipulate the table after the export has started in which case the snapshot of the data may be a factor. Export does not get an exclusive lock on any table. 

There is an option called CONSISTENT=Y. When this is enabled, EXPORT first issues a SET TRANSACTION READ ONLY command before doing the export. There is a risk of running out of rollback segment space and getting an "ORA-1555 snapshot too old (rollback segment too small)" error when doing a long running export. 


來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/35489/viewspace-1433038/,如需轉載,請註明出處,否則將追究法律責任。

相關文章