Oracle 10.2.0.1 exp 之 full database export and import(實戰)
全庫匯出,匯入實戰(資料庫版本需相同)
1 、全庫匯出
[ora@dg-ss ~]$ exp system/oracle@test file=/home/ora/full.dmp full=y
2 、檢視源庫的表空間
sys@TEST> select tablespace_name from dba_tablespaces;
TABLESPACE_NAME
------------------------------
SYSTEM
UNDOTBS1
SYSAUX
TEMP
USERS
DOUDOU
3 、遷移dmp檔案到恢復庫
[ora@dg-ss ~]$ scp full.dmp ora@192.168.0.16:/home/ora
4 、恢復庫建立表空間(源庫與恢復庫對比,如需建立表空間,請建立)
建立空間小技巧(源庫執行)
永久表空間
select 'create tablespace ' || tablespace_name ||' datafile '''||replace(file_name,'源庫資料檔案目錄/','目的 庫資料檔案目錄/') ||'''size 500m autoextend on ;' from dba_data_files ;
臨時表空間
select 'create temporary tablespace ' || tablespace_name ||' tempfile '''||replace(file_name,’ 源庫資料檔案目錄/','目的 庫資料檔案目錄/') ||'''size 500m autoextend on ;' from dba_temp_files ;
恢復庫
sys@TEST> select tablespace_name from dba_tablespaces;
TABLESPACE_NAME
------------------------------------------------------------
SYSTEM
UNDOTBS1
SYSAUX
USERS
DOUDOU
TEMP
6 、全庫匯入
[ora@dg-pp ~]$ imp system/oracle@test file=/home/ora/full.dmp full=y ignore=y
7 、成功後,建議再次全庫匯出已做備份
附表:
不同版本的全庫匯入 導致了 oracle 元件出現問題
EXP 全庫 oracle:10.2.0.1
IMP 全庫 oracle:10.2.0.4
sys@TEST> select comp_name, version, status from sys.dba_registry;
COMP_NAME VERSION STATUS
---------------------------------------- -------------------- --------------------
Oracle Enterprise Manager 10.2.0.4.0 VALID
Spatial 10.2.0.4.0 INVALID
Oracle interMedia 10.2.0.4.0 INVALID
OLAP Catalog 10.2.0.4.0 VALID
Oracle XML Database 10.2.0.4.0 VALID
Oracle Text 10.2.0.4.0 VALID
Oracle Expression Filter 10.2.0.4.0 VALID
Oracle Rule Manager 10.2.0.4.0 VALID
Oracle Workspace Manager 10.2.0.1.0 DOWNGRADED
Oracle Data Mining 10.2.0.4.0 VALID
Oracle Database Catalog Views 10.2.0.4.0 VALID
Oracle Database Packages and Types 10.2.0.4.0 VALID
JServer JAVA Virtual Machine 10.2.0.4.0 VALID
Oracle XDK 10.2.0.4.0 VALID
Oracle Database Java Packages 10.2.0.4.0 VALID
OLAP Analytic Workspace 10.2.0.4.0 VALID
Oracle OLAP API 10.2.0.4.0 VALID
解決方法:
sys@TEST> shutdown immediate;
sys@TEST> startup upgrade
sys@TEST> @?/rdbms/admin/catupgrd.sql---- 重新升級元件
sys@TEST> @?/rdbms/admin/utlrp.sql --- 重新編譯plsql失效的包
sys@TEST> select comp_name, version, status from sys.dba_registry;
COMP_NAME VERSION STATUS
---------------------------------------- ---------- ----------
Oracle Enterprise Manager 10.2.0.4.0 VALID
Spatial 10.2.0.4.0 VALID
Oracle interMedia 10.2.0.4.0 VALID
OLAP Catalog 10.2.0.4.0 VALID
Oracle XML Database 10.2.0.4.0 VALID
Oracle Text 10.2.0.4.0 VALID
Oracle Expression Filter 10.2.0.4.0 VALID
Oracle Rule Manager 10.2.0.4.0 VALID
Oracle Workspace Manager 10.2.0.4.3 VALID
Oracle Data Mining 10.2.0.4.0 VALID
Oracle Database Catalog Views 10.2.0.4.0 VALID
Oracle Database Packages and Types 10.2.0.4.0 VALID
JServer JAVA Virtual Machine 10.2.0.4.0 VALID
Oracle XDK 10.2.0.4.0 VALID
Oracle Database Java Packages 10.2.0.4.0 INVALID
OLAP Analytic Workspace 10.2.0.4.0 VALID
Oracle OLAP API 10.2.0.4.0 VALID
Oracle Database Java Packages 失效,不使用暫不處理
總結:full database export and import 需資料庫版本相同
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/26442936/viewspace-756255/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- full database export and import(實戰)DatabaseExportImport
- Oracle 12c full transportable export & importOracleExportImport
- Oracle 12c 使用(Full Transportable Export/Import)進行升級/遷移OracleExportImport
- oracle Export/Import工具使用OracleExportImport
- oracle full database backupOracleDatabase
- oracle Export and Import 簡介(轉)OracleExportImport
- Export And Import Between Different Oracle VersionsExportImportOracle
- 完全可傳輸的匯出/匯入(full transportable export/import)ExportImport
- export/importExportImport
- mysql export & importMySqlExportImport
- mysql import and exportMySqlImportExport
- Oracle不同版本之間Export & Import的相容性矩陣OracleExportImport矩陣
- import、require 、export、export default、exports、module exportsImportUIExport
- 能select的表,可以exp嗎?有exp_full_database就能exp其他使用者的表嗎?Database
- ES6 import exportImportExport
- statistics的export與import!ExportImport
- DB2 export and importDB2ExportImport
- DLL的Export和ImportExportImport
- 【轉載-ORACLE】ORA-6512 During Full ExportOracleExport
- module.exports 、 exports 和 export 、 export default 、 importExportImport
- How to perform FULL System Export/ImportsORMExportImport
- Import Error: cannot import name ‘export_saved_modelImportErrorExport
- Upgrade Oracle Database from 10.2.0.1 to 11.2.0.4OracleDatabase
- ES6模組化之export和import的用法ExportImport
- Export/import Datas To/from a Csv FileExportImport
- import,export的支援[nodejs]ImportExportNodeJS
- DataPump Export/Import Of LOBs Are Not Executed in ParallelExportImportParallel
- Data Utilities : Export and Import Utilities (57)ExportImport
- Oracle database 升級(文件)to 10.2.0.4 from 10.2.0.1OracleDatabase
- oracle 10.2.0.1 database server下載地址(轉載)OracleDatabaseServer
- 新手關於import/export的理解ImportExport
- ES6 module模組 import exportImportExport
- 1nd round export and import errorExportImportError
- Oracle工具使用(export,import,sqlldr中文幫助及例項)(轉)OracleExportImportSQL
- react-native 之匯入(import)、匯出(export)深刻解析ReactImportExport
- ORA-20010: INTERNAL ERROR: dumped min/max is null for table EXP.SYS_EXPORT_FULL_01ErrorNullExport
- exp_imp實戰
- Compatibility Matrix for Export And Import Between Different Oracle Versions [Video] [ID 132904.1]ExportImportOracleIDE