aul 学习测试(测量)
-------------------aul5 ----------test0-------------------------
select file#,rfile#,name from v$datafile
rac1-> ./...bin
Register Code: VDTL-ZSMR-RBBL-ATFV-JBKK
AUL : AnySQL UnLoader(MyDUL) for Oracle 8/8i/9i/10g/11g, release 5.1.2
(C) Copyright Lou Fangxin 2005-2010 (AnySQL.net), all rights reserved.
AUL> UNLOAD TABLE USER$;
2011-10-12 23:39:04
2011-10-12 23:39:04
AUL> UNLOAD TABLE OBJ$;
2011-10-12 23:39:14
2011-10-12 23:39:14 --這個時候查詢txt文件 你會發(fā)現(xiàn) 里面是空的
AUL> open db10g.cfg --并且必須先運行這條命令 才干夠真正吧內(nèi)容給搞出來
* ts# fno rfn ver bsize blocks filename
- ---- ---- ---- --- ----- ---------- -----------------------------------
Y 0 1 1 a2 8192 64000 /u01/app/oracle/oradata/test/system01.dbf
Y 1 2 2 a2 8192 3200 /u01/app/oracle/oradata/test/undotbs01.dbf
Y 2 3 3 a2 8192 29440 /u01/app/oracle/oradata/test/sysaux01.dbf
Y 4 4 4 a2 8192 64000 /u01/app/oracle/oradata/test/users01.dbf
AUL> UNLOAD TABLE USER$; --這樣文件就有內(nèi)容了
2011-10-12 23:39:40
2011-10-12 23:39:40
-----------------------------aul5 ----------test1--------------------
--1 conn sys/ as sysdba
create table lihj as select * from user_tables
--
select * from user_tables where table_name='LIHJ'
select * from all_users
AUL> LIST TABLE SCOTT
UNLOAD TABLE SCOTT.DEPT TO DEPT.txt;
UNLOAD TABLE SCOTT.EMP TO EMP.txt;
UNLOAD TABLE SCOTT.BONUS TO BONUS.txt;
UNLOAD TABLE SCOTT.SALGRADE TO SALGRADE.txt;
AUL> UNLOAD TABLE SCOTT.DEPT ;
2011-10-12 23:52:29
Unload OBJD=51146 FILE=4 BLOCK=11 CLUSTER=0 ...
10|ACCOUNTING|NEW YORK
20|RESEARCH|DALLAS
30|SALES|CHICAGO
40|OPERATIONS|BOSTON
Sucessfully unload 4 rows ...
2011-10-12 23:52:29
-------------------------------aul5-----------test2---------------------------
--以下的實驗證明了一個小問題:先要unload字典,system的用戶創(chuàng)建的可能unload不出來
AUL> UNLOAD TABLE USER$;
2011-10-12 23:51:02
2011-10-12 23:51:02
AUL> UNLOAD TABLE OBJ$;
2011-10-12 23:51:08
2011-10-12 23:51:08
AUL> UNLOAD TABLE TAB$;
2011-10-12 23:51:13
2011-10-12 23:51:13
AUL> UNLOAD TABLE COL$;
2011-10-12 23:51:18
2011-10-12 23:51:19
AUL> UNLOAD TABLE LIHJ
2 ;
AUL> LIST TABLE SCOTT
-------------------------------------------注意這些步驟的順序。剛剛checkpoint的數(shù)據(jù)要又一次載入
UNLOAD TABLE SCOTT.DEPT TO DEPT.txt;
UNLOAD TABLE SCOTT.EMP TO EMP.txt;
UNLOAD TABLE SCOTT.BONUS TO BONUS.txt;
UNLOAD TABLE SCOTT.SALGRADE TO SALGRADE.txt;
AUL> UNLOAD TABLE SCOTT.DEPT ;
2011-10-12 23:52:29
Unload OBJD=51146 FILE=4 BLOCK=11 CLUSTER=0 ...
10|ACCOUNTING|NEW YORK
20|RESEARCH|DALLAS
30|SALES|CHICAGO
40|OPERATIONS|BOSTON
Sucessfully unload 4 rows ...
2011-10-12 23:52:29
AUL> LIST TABLE SCOTT;
UNLOAD TABLE SCOTT.DEPT TO DEPT.txt;
UNLOAD TABLE SCOTT.EMP TO EMP.txt;
UNLOAD TABLE SCOTT.BONUS TO BONUS.txt;
UNLOAD TABLE SCOTT.SALGRADE TO SALGRADE.txt;
AUL> UNLOAD TABLE USER$;
2011-10-12 23:57:47
2011-10-12 23:57:47
AUL> UNLOAD TABLE OBJ$;
2011-10-12 23:57:47
UNLOAD TABLE TAB$;
UNLOAD TABLE COL$;
LIST TABLE SCOTT
2011-10-12 23:57:47
AUL> 2011-10-12 23:57:47
2011-10-12 23:57:47
AUL> 2011-10-12 23:57:47
2011-10-12 23:57:47
AUL>
UNLOAD TABLE SCOTT.DEPT TO DEPT.txt;
UNLOAD TABLE SCOTT.EMP TO EMP.txt;
UNLOAD TABLE SCOTT.BONUS TO BONUS.txt;
UNLOAD TABLE SCOTT.SALGRADE TO SALGRADE.txt;
UNLOAD TABLE SCOTT.LIHJ TO LIHJ.txt;
AUL> UNLOAD TABLE LIHJ
2 ;
AUL> UNLOAD TABLE SCOTT.LIHJ;
2011-10-12 23:58:25
Unload OBJD=51626 FILE=4 BLOCK=1387 CLUSTER=0 ...
DEPT|USERS|||VALID|10||1|255|65536||1|2147483645||||YES|N||||||||| 1| 1| N|ENABLED|||NO||N|N|NO|DEFAULT|DISABLED|NO|NO||DISABLED|YES||DISABLED|DISABLED|NO
EMP|USERS|||VALID|10||1|255|65536||1|2147483645||||YES|N||||||||| 1| 1| N|ENABLED|||NO||N|N|NO|DEFAULT|DISABLED|NO|NO||DISABLED|YES||DISABLED|DISABLED|NO
BONUS|USERS|||VALID|10||1|255|65536||1|2147483645||||YES|N||||||||| 1| 1| N|ENABLED|||NO||N|N|NO|DEFAULT|DISABLED|NO|NO||DISABLED|YES||DISABLED|DISABLED|NO
SALGRADE|USERS|||VALID|10||1|255|65536||1|2147483645||||YES|N||||||||| 1| 1| N|ENABLED|||NO||N|N|NO|DEFAULT|DISABLED|NO|NO||DISABLED|YES||DISABLED|DISABLED|NO
Sucessfully unload 4 rows ...
2011-10-12 23:58:25
---------------------------------------------------------------------------------------------
open db10g.cfg
unload table USER$
unload table OBJ$
unload table TAB$
unload table COL$ --以上四個步驟好像都須要的
--剛剛開始的時候 前面不能加入
SET FIELD_TAG x07
SET RECORD_TAG x06unload table sys.view$ to sys_view2.txt;
--視圖能夠搞出來 牛
--關(guān)鍵是數(shù)據(jù)
---------------------------------下面的順序算是比較成功的------------------------------------
open db10g.cfg --這個文件須要上傳的
unload table USER$;
unload table OBJ$;
unload table TAB$;
unload table COL$;
set field_tag x07
set record_tag x06
---下面的命令能夠同一時候生成ctl文件和sql文件,,以后用這個順序做
unload table sys.source$ to sys_source.txt;
unload table scott.dept to scott_dept.txt;
-----系統(tǒng)生成的文件
rac1-> ll
total 32460
-rw-r--r-- 1 oracle oinstall 2328529 Oct 13 00:31 AULCOL.TXT
-rw-r--r-- 1 oracle oinstall 1868268 Oct 13 00:29 AULOBJ.TXT
-rw-r--r-- 1 oracle oinstall 84655 Oct 13 00:31 AULTAB.TXT
-rw-r--r-- 1 oracle oinstall 874 Oct 13 00:29 AULUSR.TXT
-rw-r--r-- 1 oracle oinstall 293 Oct 13 00:34 DEPT_sqlldr.ctl
-rw-r--r-- 1 oracle oinstall 108 Oct 13 00:34 DEPT_syntax.sql
-rw-r--r-- 1 oracle oinstall 295 Oct 13 00:31 SOURCE__sqlldr.ctl
-rw-r--r-- 1 oracle oinstall 112 Oct 13 00:31 SOURCE__syntax.sql
-rwxr-xr-x 1 oracle oinstall 352196 Jun 28 15:23 aul5b_linux.bin
-rw-r--r-- 1 oracle oinstall 185 Oct 12 23:34 db10g.cfg
-rw-r--r-- 1 oracle oinstall 80 Oct 13 00:34 scott_dept.txt
-rw-r--r-- 1 oracle oinstall 28532163 Oct 13 00:31 sys_source.txt
---假設(shè)是刪除的數(shù)據(jù)該怎么恢復(fù)呢!否則僅僅能恢復(fù)現(xiàn)有的重要的數(shù)據(jù)。工具的局限性大的工具由大牛編寫。局限性非常強。做好備份。非常重要:
相比之下該文章更有借鑒性(偷梁換柱——極端情況下的數(shù)據(jù)解救)
http://www.hellodba.com/reader.php?
ID=210&lang=CN
版權(quán)聲明:本文博主原創(chuàng)文章。博客,未經(jīng)同意不得轉(zhuǎn)載。
總結(jié)
以上是生活随笔為你收集整理的aul 学习测试(测量)的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 深度学习之基于CNN实现天气识别
- 下一篇: 深度学习之基于卷积神经网络(VGG16C