exp
exp 用戶名/密碼@數(shù)據(jù)庫SID
owner=用戶名
file=路徑/exp_2018.dmp
log=路徑/log_2018.log
imp
imp用戶名/密碼@數(shù)據(jù)庫SID
file=路徑/exp_2018.dmp(已存在)
log=路徑/imp_2018.log
full=y
ignore=y
expdp
1.創(chuàng)建目錄
????mkdir /hoem/oracle/oracle_bak
????連接數(shù)據(jù)庫
????????sqlplus /nolog
????????conn sys/7961314@orcl as sysdba
????create directory aa as '/hoem/oracle/oracle_bak'
????drop directory aa
2.授權(quán)
grant read,write on directory aa to system;
3.執(zhí)行導(dǎo)出
expdp用戶名/密碼@數(shù)據(jù)庫SID
directory=aa
dumpfile=路徑/expdp_2018.dmp
logfile=路徑/log_2018.log
schemas=hs_user
impdp
1.連接數(shù)據(jù)庫
????sqlplus /as sysdba
????create directory aa as '/hoem/oracle/oracle_bak'
????drop directory aa
2.授權(quán)
grant read,write on directory aa to system;
3.執(zhí)行導(dǎo)入
impdp用戶名/密碼@數(shù)據(jù)庫SID
directory=aa
dumpfile=路徑/expdp_2018.dmp
logfile=路徑/log_2018.log
schemas=hs_user
table_exists_actiom=truncate/replace