oracle 10g資料遷移到11g

2021-06-18 02:43:58 字數 1342 閱讀 4464

首先使用expdp匯出原資料庫:

expdp system/***xx   schemas=test1201 directory=asbak  dumpfile=test1201.dmp  logfile=zytest1201.log;

impdp前的準備:

1:確保目標資料庫和原庫的字符集一致

2:建立好所需表空間,可在原庫里查詢test1201這個使用者使用了哪些一表空間查詢語句如下:

select distinct tablespace_name  from  dba_segments where owner='test1201';

然後建立好錶空間,臨時表空間就不需要建立了,

autoextend  on next 10m maxsize  unlimited autoallocate;

3.表空間建立好之後,就需要建立使用者了 ,並需要使用者授權,許可權和原庫使用者的許可權保持一致

建立使用者:create  user test1201  identified  by kingdee  default  tablespace eas_d_test1201_standard quota unlimited on

eas_d_test1201_standard  quota umlimited on eas_d_test1201_temp2;

查詢原庫使用者的許可權:select * from dba_sys_privs  where  gratee='test1201';

然後給使用者授權:grant  create view,create sequence,unlimited tablespace,select any dictionary,create  proceduer,create table,create trigger,create  materialized view,create session  to test1201;

4.建立directory,並給使用者授予讀寫許可權:

grant write,read on directory orabak to test1201;

前面的4個點做好之後就開始匯入資料了:

將上面匯出的檔案拷貝到orabak的這個目錄裡然後開始匯入

impdp  system/***xx  schemas=test1201 dumpfile=test1201.dmp  logfile=expdp_test11.log  directory=orabak  table_exists_action=replace  job_name=job5;

匯入的時候會提示乙個ora_31684:object type user:"***" already exists。這個沒有關係 ,然後看日誌有沒有錯,如果沒有,則成功。

oracle 10g 資料庫遷移

它是最常用最簡單的方法,一般是基於應用的owner級做匯出匯入。操作方法為 在新庫建立好owner和表空間,停老庫的應用,在老庫執行 exp user pwd owner file exp dmp log exp log buffer 6000000,匯入dmp檔案到新庫,在新庫執行如下命令 imp...

資料庫停機遷移oracle10g例項

檢視使用者系統許可權 sql select from user sys privs 檢視使用者擁有的角色 sql select from user role privs 檢視當前會話的許可權 sql select from session privs privilege create session...

oracle10g 解除安裝

1 oracle 10g解除安裝軟體環境 1 windows xp oracle 10g2 oracle 安裝路徑為 d oracle 實現方法 1 開始 設定 控制面板 管理工具 服務停止所有 oracle 服務 2 開始 程式 oracle oradb 10g home1 oracle inst...