在归档模式下,用IMMEDIATE选项OFFLINE表空间后,如果需要ONLINE该表空间,需要先执行介质恢复(media recovery),如:
SQL> alter tablespace OCPTBS offline immediate;
Tablespace altered.
SQL> alter tablespace OCPTBS online;
alter tablespace OCPTBS online
*
ERROR at line 1:
ORA-01113: file 5 needs media recovery
ORA-01110: data file 5:
+XINER_DATA/xiner/datafile/ocptbs.268.745970939'
如果直接online的话,会提示file 5需要介质恢复。
SQL> recover tablespace OCPTBS;
Media recovery complete.
SQL> ALTER TABLESPACE OCPTBS ONLINE;
Tablespace altered.
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/25834554/viewspace-1050962/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/25834554/viewspace-1050962/