linux读取dmp备份数据打开,Linux 中 Oracle dmp 文件导入导出(转)
遠程工具連接到 Linux 進行操作,進行 Linux 上 dmp 文件的導入導出。
1.將用戶 system 用戶表導出到指定路徑 D 盤
exp system/password@SID file=d:/daochu.dmp full=y
2.將用戶 system 與 sys 用戶的表導出到指定路徑 D 盤
exp system/password@SID file=d:/daochu.dmp owner=(system,sys)
3.將用戶 system 中的表 table_A、table_B 導出到指定路徑 D 盤
exp system/password@SID file= d:/daochu.dmp tables=(table_A,table_B)
4.將用戶 system 中的表 table1 中的字段 filed1 以"00"打頭的數據導出
exp system/passwor@SID filed=d:/daochu.dmp tables=(table1) query=/" where filed1 like '00%'/"
對于壓縮可以用 winzip 將 dmp 文件進行壓縮,也可以在上面命令后面 加上 compress=y 來實現。
導出 DMP文件適用于大型數據庫完整遷移,對遷移前后兩者服務器數據庫字符集要求一致,且對CLOB字段支持不太友好。
對于小數據的導出其實用 PLSQL 能做的更好,更快,導出的SQL也很直觀。
5.將 D:/daochu.dmp 中的數據導入 TEST 數據庫中。
imp system/password@SID file=d:/daochu.dmp
imp system/password@HUST full=y file=d:/data/newsmgnt.dmp ignore=y
上面命令如果出現問題,假設有的表已存在,對該表可以不進行導入,后面添加 ignore=y。
6.將 d:/daochu.dmp中的表table1 導入
imp system/passord@SID file=d:/daochu.dmp tables=(table1)
附:
nohup可以使進程后臺執行,防止xshell斷開時進程終止
導入大量的數據時:nohup imp lunzhiyu/123456@orcl full=y file=tb_rns_qq_name.dmp ignore=y &
總結
以上是生活随笔為你收集整理的linux读取dmp备份数据打开,Linux 中 Oracle dmp 文件导入导出(转)的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Anaconda:包安装以XGBoost
- 下一篇: Anaconda:conda insta