View a markdown version of this page

階段 4 – 驗證傳輸的資料 - AWS 方案指引

本文為英文版的機器翻譯版本,如內容有任何歧義或不一致之處,概以英文版為準。

階段 4 – 驗證傳輸的資料

步驟 1:檢查資料表空間是否損毀

在此步驟中,傳輸的資料表空間只會在目的地資料庫中讀取。您可以執行 RMAN 命令來驗證資料表空間是否有效,如下所示。

sqlplus / as sysdba; set feedback off set pagesize 0 set heading off spool tbs_val.sql; select 'validate tablespace '||tablespace_name||' check logical;' from dba_tablespaces where tablespace_name not in ('SYSTEM','SYSAUX','TEMP','USERS','UNDOTBS1','UNDOTBS2','UNDOTBS3','UNDOTBS3','UNDOTBS4'); spool off; exit; --Remove the first and last line in the spool file, tbs_val.sql rman target / RMAN> @tbs_val.sql

此外,您可以檢查物件的計數,例如資料表、索引、同義詞、檢視和套件物件。

步驟 2. 將目的地資料庫中的所有傳輸資料表空間設為讀取/寫入

sqlplus / as sysdba; set feedback off set pagesize 0 set heading off spool tbs_rw.sql select 'alter tablespace '||tablespace_name||' read write;' from dba_tablespaces where status='READ ONLY'; spool off; exit; --Remove the first and last line in the spool file, tbs_rw.sql sqlplus / as sysdba; SQL> @tbs_rw.sql