(3)全庫方式,将資料庫中的所有對象導出/導入導出:
$ exp user/[email protected] file = /dir/xxx.dmp log = xxx.log full = y
注:user/[email protected]:要導出的使用者名/密碼@SID名,該使用者應該有dba權限
File :導出轉儲檔案的名字
Full :如設為‘Y’,那麼将執行一個整個資料庫導出操作
Commit: 送出數組插入 (N)
Ignore: 忽略建立錯誤
導入:
$ imp user/[email protected] file=/dir/xxx.dmp log=xxx.log fromuser=dbuser touser=dbuser2
注:user/[email protected]:使用者名/密碼@SID名,該使用者應該有dba權限
File :導入轉儲檔案的名字
Log : 導入日志将要寫入的檔案的名字
fromuser : 在FULL=N的情況下,才有參數。它是一系列的資料庫帳号,其對象應從導出轉儲檔案中讀取
touser : 一系列資料庫帳号,導出轉儲檔案扣的對象将要導入這些帳号
注:
擷取幫助方法如下:
$ exp help=y
$ imp help=y