dul 10g版本的使用
dul 10g版本的使用
在自己的測試環境下(linux平臺)測試下10g dul工具的使用
資料庫表空間使用的有ASM管理的磁碟組,也有一般的資料檔案
1)建立表空間
create tablespace TBSDATA3 datafile '+DSKGRP1' size 100M;
create table testdul (name varchar2(20)) tablespace TBSDATA3;
select name,path,total_mb,free_mb,failgroup from v$asm_disk
NAME PATH TOTAL_MB FREE_MB FAILGROUP
-------------------- ---------------------------------------- ---------- ---------- ------------------------------------------------------------
/dev/sdc 1024 0
/dev/sdd 1024 0
/dev/sdd3 196 0
/dev/sdd4 196 0
DSKGRP1_0000 /dev/sdc1 196 52 DSKGRP1_0000
DSKGRP1_0001 /dev/sdc2 196 27 DSKGRP1_0001
DSKGRP1_0002 /dev/sdc3 196 34 DSKGRP1_0002
DSKGRP1_0003 /dev/sdc4 196 57 DSKGRP1_0003
DSKGRP1_0004 /dev/sdd1 196 47 DSKGRP1_0004
DSKGRP1_0005 /dev/sdd2 196 58 DSKGRP1_0005
可以看到使用了具體下列盤
/dev/sdc1
/dev/sdc2
/dev/sdc3
/dev/sdc4
/dev/sdd1
/dev/sdd2
2)編寫init.dul檔案
OSD_BIG_ENDIAN_FLAG=FALSE
osd_dba_file_bits = 10
osd_c_struct_alignment = 32
osd_file_leader_size = 1
dc_columns=200000
dc_tables=100000
dc_objects=100000
dc_users = 40
dc_segments=100000
db_block_size=8192
control_file=/oracle/orainstall/dul10/control.dul
export_mode=true
compatible=10
3)編寫control.dul檔案
使用select ts#, rfile#, name from v$datafile查詢資料檔案及表空間資訊
注意在該檔案中新增ASM磁碟資訊
disk /dev/sdc1
disk /dev/sdc2
disk /dev/sdc3
disk /dev/sdc4
disk /dev/sdd1
disk /dev/sdd2
0 1 /oradata/orcl/system01.dbf
1 2 /oradata/orcl/undotbs01.dbf
2 3 /oradata/orcl/sysaux01.dbf
4 4 /oradata/orcl/undotbs02.dbf
5 5 /oradata/orcl/users01.dbf
6 6 /oradata/orcl/testdata01.dbf
7 7 /oradata/orcl/TEST02.DBF
7 5 /oradata/orcl/TEST01.DBF
8 1024 /oradata/orcl/BIGFILE01.DBF
13 10 +DSKGRP1/orcl/datafile/tbsdata1.256.664401755
14 11 +DSKGRP1/orcl/datafile/tbsdata2.257.664401765
15 7 /oradata/trans/TEST02.DBF
15 6 /oradata/trans/TEST01.DBF
16 14 /oradata/orcl/RMAN01.DBF
17 15 +DSKGRP1/orcl/datafile/tbsdata3.267.684263423
4)關閉資料庫及ASM例項
export ORACLE_SID=+ASM1
sqlplus "/ as sysdba"
SQL> shutdown abort
ASM instance shutdown
5)dul使用者及表,可以看到資料庫在沒有開啟及ASM例項沒有啟動的情況下,仍然能匯出資料
./dul
DUL>bootstrap;
DUL>DUL> unload user scott;
About to unload SCOTT's tables ...
. unloading table DEPT 4 rows unloaded
. unloading table EMP 14 rows unloaded
. unloading table BONUS 0 rows unloaded
. unloading table SALGRADE 5 rows unloaded
. unloading table READTAB 4 rows unloaded
. unloading table TT_03_SYNC_OBJS 3 rows unloaded
. unloading table TT_03_USER_COUNT 1 row unloaded
. unloading table TT_03_AGENT_STATUS 2 rows unloaded
. unloading table TT_03_49127_L 1 row unloaded
. unloading table TESTDUL 1000 rows unloaded
DUL> unload table testdul;
. unloading table TESTDUL 1000 rows unloaded
6)先刪除一個table
$ sqlplus scott/tiger
SQL> drop table testdul purge;
Table dropped.
DUL> unload table scott.testdul;
. unloading table TESTDUL 1000 rows unloaded
可以看到在dul工具在這個表的空間沒有被覆蓋的時候仍然能取到這個表
[@more@]
在自己的測試環境下(linux平臺)測試下10g dul工具的使用
資料庫表空間使用的有ASM管理的磁碟組,也有一般的資料檔案
1)建立表空間
create tablespace TBSDATA3 datafile '+DSKGRP1' size 100M;
create table testdul (name varchar2(20)) tablespace TBSDATA3;
select name,path,total_mb,free_mb,failgroup from v$asm_disk
NAME PATH TOTAL_MB FREE_MB FAILGROUP
-------------------- ---------------------------------------- ---------- ---------- ------------------------------------------------------------
/dev/sdc 1024 0
/dev/sdd 1024 0
/dev/sdd3 196 0
/dev/sdd4 196 0
DSKGRP1_0000 /dev/sdc1 196 52 DSKGRP1_0000
DSKGRP1_0001 /dev/sdc2 196 27 DSKGRP1_0001
DSKGRP1_0002 /dev/sdc3 196 34 DSKGRP1_0002
DSKGRP1_0003 /dev/sdc4 196 57 DSKGRP1_0003
DSKGRP1_0004 /dev/sdd1 196 47 DSKGRP1_0004
DSKGRP1_0005 /dev/sdd2 196 58 DSKGRP1_0005
可以看到使用了具體下列盤
/dev/sdc1
/dev/sdc2
/dev/sdc3
/dev/sdc4
/dev/sdd1
/dev/sdd2
2)編寫init.dul檔案
OSD_BIG_ENDIAN_FLAG=FALSE
osd_dba_file_bits = 10
osd_c_struct_alignment = 32
osd_file_leader_size = 1
dc_columns=200000
dc_tables=100000
dc_objects=100000
dc_users = 40
dc_segments=100000
db_block_size=8192
control_file=/oracle/orainstall/dul10/control.dul
export_mode=true
compatible=10
3)編寫control.dul檔案
使用select ts#, rfile#, name from v$datafile查詢資料檔案及表空間資訊
注意在該檔案中新增ASM磁碟資訊
disk /dev/sdc1
disk /dev/sdc2
disk /dev/sdc3
disk /dev/sdc4
disk /dev/sdd1
disk /dev/sdd2
0 1 /oradata/orcl/system01.dbf
1 2 /oradata/orcl/undotbs01.dbf
2 3 /oradata/orcl/sysaux01.dbf
4 4 /oradata/orcl/undotbs02.dbf
5 5 /oradata/orcl/users01.dbf
6 6 /oradata/orcl/testdata01.dbf
7 7 /oradata/orcl/TEST02.DBF
7 5 /oradata/orcl/TEST01.DBF
8 1024 /oradata/orcl/BIGFILE01.DBF
13 10 +DSKGRP1/orcl/datafile/tbsdata1.256.664401755
14 11 +DSKGRP1/orcl/datafile/tbsdata2.257.664401765
15 7 /oradata/trans/TEST02.DBF
15 6 /oradata/trans/TEST01.DBF
16 14 /oradata/orcl/RMAN01.DBF
17 15 +DSKGRP1/orcl/datafile/tbsdata3.267.684263423
4)關閉資料庫及ASM例項
export ORACLE_SID=+ASM1
sqlplus "/ as sysdba"
SQL> shutdown abort
ASM instance shutdown
5)dul使用者及表,可以看到資料庫在沒有開啟及ASM例項沒有啟動的情況下,仍然能匯出資料
./dul
DUL>bootstrap;
DUL>DUL> unload user scott;
About to unload SCOTT's tables ...
. unloading table DEPT 4 rows unloaded
. unloading table EMP 14 rows unloaded
. unloading table BONUS 0 rows unloaded
. unloading table SALGRADE 5 rows unloaded
. unloading table READTAB 4 rows unloaded
. unloading table TT_03_SYNC_OBJS 3 rows unloaded
. unloading table TT_03_USER_COUNT 1 row unloaded
. unloading table TT_03_AGENT_STATUS 2 rows unloaded
. unloading table TT_03_49127_L 1 row unloaded
. unloading table TESTDUL 1000 rows unloaded
DUL> unload table testdul;
. unloading table TESTDUL 1000 rows unloaded
6)先刪除一個table
$ sqlplus scott/tiger
SQL> drop table testdul purge;
Table dropped.
DUL> unload table scott.testdul;
. unloading table TESTDUL 1000 rows unloaded
可以看到在dul工具在這個表的空間沒有被覆蓋的時候仍然能取到這個表
[@more@]
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/48010/viewspace-1020666/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 10G密碼版本使用者無法登陸問題密碼
- Oracle DUL的工作原理和技術實現Oracle
- [20180412]logminer使用問題(10g).txt
- 【10g SQL新特性】q-quote使用SQL
- 10G FGA的增強
- 【問題處理】升級12c之後,10G密碼版本使用者無法登陸問題密碼
- 10g sqlplus的一個bugSQL
- Git 版本控制工具的使用Git
- 10g RAC on AIXAI
- 使用perl比較mysql的版本MySql
- 近期使用10G時遇到的兩個問題:Memory Notification和ORA-3136
- 10G DG SWITCH OVER
- oracle 10g flashback databaseOracle 10gDatabase
- go cron v3 版本的使用Go
- Scheduler in Oracle Database 10g(轉)OracleDatabase
- Oracle 10g 下載地址Oracle 10g
- oracle 10G特性之awrOracle 10g
- forall在10g新功能
- 【exp/imp不同版本】Oracle不同版本的exp/imp使用注意事項Oracle
- [20190415]10g下那些latch是共享的.txt
- 關於Oracle 10g ASM磁碟大小的限制Oracle 10gASM
- 10g的回收站又惹禍了
- SpringBoot dubbo 的簡單使用註解版本Spring Boot
- Dotnet Core使用特定的SDK&Runtime版本
- 優雅的使用 Brew 切換 Go 版本Go
- 如何在 XAMPP 中使用 不同的 PHP 版本PHP
- oracle 10g建立資料庫鏈的簡化Oracle 10g資料庫
- [20190102]關於字串的分配問題(10g).txt字串
- 如何手工重建10g database consoleDatabase
- ISO 映象安裝oracle 10gOracle 10g
- Oracle 10g RAC故障處理Oracle 10g
- [20190530]DISABLE TABLE LOCK(10g).txt
- [20190215]那個更快(10g).txt
- Oracle 10g 增刪節點Oracle 10g
- 版本控制軟體Git的安裝與使用Git
- Consul Config 使用Git做版本控制的實現Git
- 如何使用Git 優雅的版本回退呢?Git
- C++11新版本“for的使用“和“auto“C++
- Oracle 10g(10.1.0.2)中的OPTIMIZER_INDEX_COST_ADJ(轉)Oracle 10gIndex