国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 開發 > 綜合 > 正文

數據字典表Truncate掉將導致數據庫不可用

2024-07-21 02:43:17
字體:
來源:轉載
供稿:網友
在實際的工作環境下,如果你在操作時將數據庫內的幾個數據字典表Truncate掉,將會直接導致數據庫不能再繼續使用,本文將針對一個相關案例進行詳細的講解。

案例如下:

數據庫環境:Oracle數據庫9.2.0.7 RAC。(注:由于數據庫的事務量體別大,所以數據庫沒有進行備份)。

檢查后發現的被截斷表:

SQL> select object_name,object_type from dba_objects where object_name like 'IDL%';OBJECT_NAME            OBJECT_TYPE------------------- ------------------IDL_CHAR$                 TABLEIDL_SB4$                  TABLEIDL_UB1$                  TABLEIDL_UB2$                  TABLE

IDL_UB1$表是特別重要的字典表,只要出現故障,數據庫就會出現大量的ORA-00600錯誤,所有事務將不能進行。

ORA-00600: internal error code, arguments: [17069],[0xC0000000DDDFA690], [], [], [], [], [], []

ORA-600 17069錯誤是一個特別難解決的問題,問題出現后數據庫的某個跟蹤日志很快就會出現暴漲的情況,因為IDL系列字典表是記錄數據庫對象編譯信息的,丟失了其中的數據,所有過程、Package等都將無法執行。

字典表作用的說明:

IDL_UB1$ is one of four tables that hold compiled PL/SQL code:IDL_UB1$IDL_CHAR$IDL_UB2$IDL_SB4$"PL/SQL is based on the PRogramming language Ada. As a result, PL/SQL uses avariant of Descriptive Intermediate Attributed Notation for Ada (DIANA), whichis a tree-structured intermediate language. It is defined using a meta-notationcalled Interface Definition Language (IDL). DIANA provides for communicationinternal to compilers and other tools."At compile time, PL/SQL source code is translated into machine-readablem-code.Both the DIANA and m-code for a procedure or package are stored in thedatabase.At run time, they are loaded into the shared (memory) pool. The DIANA isused to compile dependent procedures; the m-code is simply executed."These four tables hold the DIANA and the so-code m-code. I think "m-code" isshort for machine-dependent byte code but there is a sizable machine-indenpendent partas well. If you have a look at sql.bsq, you can seethat Oracle documents the "type" column of these tables as follows:part number not null,/* part: 0 = diana, 1 = portable pcode, 2 = machine-dependentpcode */

如果出現更為嚴重的情況,它將導致大量系統DBMS包失效,其重新編譯也將更為復雜。

恢復數據庫,消除所有ORA-600錯誤的方法:

恢復的方法是通過運行相關的腳本,重建和重新編譯所有Procedure/Trigger/Package等對象,重新生成這些對象的DIANA和so-code m-code,主要包括catlog.sql,catproc.sql等腳本。

注意:即使以花費大量的時間為代價,一些ORA-00600錯誤也必須解決。


發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 泌阳县| 山东省| 焉耆| 普洱| 赤壁市| 福安市| 揭阳市| 桐乡市| 丹巴县| 商河县| 高州市| 志丹县| 邢台县| 卢龙县| 黄平县| 达州市| 靖江市| 乌拉特后旗| 金秀| 徐水县| 康马县| 绍兴县| 循化| 原平市| 贵溪市| 广汉市| 桦南县| 万州区| 鄯善县| 视频| 锡林郭勒盟| 万年县| 上林县| 德格县| 安徽省| 施秉县| 安福县| 宜章县| 宣汉县| 黎平县| 灵宝市|