当前位置:  数据库>oracle

Oracle ORA-04045 errors during recompilation/revalidation

    来源: 互联网  发布时间:2017-06-02

    本文导语: 系统环境:CentOS release 5.10 - 64 bit 应用环境:Oracle 10.2.0.5 错误摘要: 错误原由:   由10.2.0.1升级到10.2.0.5,upgrade mode运行utlirp.sql而没有重新刷新对象导致:  DOC>####################################################################### DOC>########...

系统环境:CentOS release 5.10 - 64 bit
 
应用环境:Oracle 10.2.0.5

错误摘要:


















































错误原由:
 
  由10.2.0.1升级到10.2.0.5,upgrade mode运行utlirp.sql而没有重新刷新对象导致:
 

DOC>#######################################################################
 
DOC>#######################################################################
 
DOC>  utlirp.sql completed successfully. All PL/SQL objects in the
 
DOC>  database have been invalidated.
 
DOC>
 
DOC>  Shut down and restart the database in normal mode and run utlrp.sql to
 
DOC>  recompile invalid objects.
 
DOC>#######################################################################
 
DOC>#######################################################################

解决方法:
 
  sysdba执行ORACLE_HOME/rdbms/admin/utlrp.sql 脚本

  另外还有两种编译无效对象的方式: 
 
      1 使用alter **** compile 语句进行编译 
 
      2 用DBMS_UTILITY包来进行编译.

相关介绍:

====================================================================
 
=====What is the Difference between UTLRP.SQL, UTLIRP.SQL and UTLIP.SQL?====
 
====================================================================

About UTLRP.SQL
 ===============
 
+ What is UTLRP.SQL?
 This script recompiles invalid PLSQL modules.
 NOTE: This script DOES NOT Invalidate any PLSQL modules like utlirp.sql and utlip.sql
 
+ What this script does?
 This script recompiles all existing invalid PL/SQL modules in a database.
 This is a fairly general script that can be used at any time to recompile all existing invalid PL/SQL modules in a database If run as one of the last steps during migration/upgrade/downgrade this script will validate all PL/SQL modules (i.e. procedures, functions, packages, triggers, types, views, libraries) during the migration step itself.
 
+ Any other script called within UTLRP.SQL?
 Yes. It invokes utlrcmp.sql
 
+ When it is best to run UTLRP.SQL?
 Although invalid PL/SQL modules get automatically recompiled on use, it is useful to run this script ahead of time (e.g. as one of the last steps in your migration), since this will either eliminate or minimize subsequent latencies caused due to on-demand automatic recompilation at runtime. Oracle highly recommends running this script towards the end of any database migration/upgrade/downgrade.
 

About UTLIRP.SQL
 ===============
 
+ What is UTLIRP.SQL ?
 This is a SQL script which Invalidates PL/SQL modules viz.,procedures, functions, packages, types, triggers, views in a database This script expects standard.sql, dbmsstdx.sql files to be available in the current directory.
 There should be no other DDL on the database while running the script.
 
+ What UTLIRP.SQL does?
 
In 9i:
 
The utlirp.sql script recompiles existing PL/SQL modules in the FORMAT required by the NEW DATABASE with the below steps:
 
A. This script first alters certain dictionary tables.
 
B. Then, it reloads package STANDARD and DBMS_STANDARD,which are necessary for using PL/SQL.
 
C. Finally, it triggers a recompile of all PL/SQL modules, such as packages,procedures, types, and so on. Primarily used for WORD-SIZE conversion
 
In 10g and higher:
 
The utlirp.sql script recompiles existing PL/SQL modules in the FORMAT required by the NEW DATABASE with the below steps:
 
A. This script first alters certain dictionary tables.
 
B. Then, it reloads package STANDARD and DBMS_STANDARD, which are necessary for using PL/SQL.  All DDL Triggers are compiled at this time as well.
 
C. Unlike in 9i, the database must be restarted and UTLRP.SQL run to recompile the remaining invalid objects.
 

+ Any other script called within UTLIRP.SQL?
 Yes. It invokes utlip.sql and utlrp.sql
 
+ When it is best to run UTLIRP.SQL?
 A) Must during WORD-SIZE conversion where it first Invalidates PLSQL modules and then recompiles PLSQL modules in the FORMAT required by the NEW DATABASE. This situation makes sense because an action was taken that caused the old code's format to be inconsistent with what it's supposed to be. e.g., when migrating a 32 bit database to a 64 bit database or vice-versa
 
B) Can also be run whenever UTLRP.SQL needs to be run to validate invalid objects as this script only invalidates and then validates all the PLSQL modules.
 

About UTLIP.SQL
 ==============
 
+ What is UTLIP.SQL
 This script Invalidates PL/SQL modules. This script can be used to invalidate all existing PL/SQL modules (i.e. procedures, functions, packages, types, triggers, views) in a database so that they will be FORCED to be RECOMPILED LATER on either automatically or deliberately. Run this script connected as SYSDBA from SQL*PLUS. This script expects the following files to be available in the current directory: standard.sql, dbmsstdx.sql, dbmssql.sql, prvtssql.plb, prvtsql.plb, plitblm.sql
 There should be no other DDL on the database while running the script.
 
+ What UTLIP.SQL does?
 This script regenerates the compiled code because an action was taken that caused the old code's format to be inconsistent with what it's supposed to be. e.g., when migrating a 32 bit database to a 64 bit database or vice-versa. THIS IS THE ACTUAL SCRIPT WHICH DOES THE REGENERATION OF COMPILED CODE. The actual series of steps can be checked reading the script which has a few step by step operations
 
+ Any other script called within UTLIP.SQL?
 Yes. It calls standard, dbmsstdx
 
+ When it is best to run UTLIP.SQL?
 The best would be during WORD-SIZE conversion from 32bit to 64bit and vice-versa.
 

Where are these SCRIPTS located?
 ============================
 
The scripts are found in the standard admin directory of the Oracle Home.
 $ORACLE_HOME/rdbms/admin
 

Which script is better?
 =================
 
-> UTLIP.SQL - This is the actual script which does the regeneration of compiled code.
 
-> UTLRP.SQL - Validates all invalid objects and can be run anytime. (this in-turn is called by utlirp.sql)
 
-> UTLIRP.SQL - Simply calls utlip.sql and utlrp.sql(9i only) which MUST be run during WORD-SIZE conversion (If utlip.sql is not run manually) and during normal validating of invalid objects. (if utlrp.sql is not run)
 

Summary
 ========
 
The best would be to run UTLIRP.SQL which would do both regeneration of compiled code of PL/SQL modules (which UTLIP.SQL does) and then Recompiles all Invalid PL/SQL modules again. (which UTLRP.SQL does)


    
 
 

您可能感兴趣的文章:

 
本站(WWW.)旨在分享和传播互联网科技相关的资讯和技术,将尽最大努力为读者提供更好的信息聚合和浏览方式。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。












  • 相关文章推荐
  • Error: oracle/jdbc/driver/oracledriver has been reported,这是怎么回事,谢谢!
  • oracle817在redhat7.3上安装出现:Error in invoking target relink of makeifle
  • Oracle Error Workaround
  • 安装oracle出现error:ora-01031:insufficient privilleges的解决
  • Redhat AS4 安装 oracle10g出现 Error in invoking target 'client_sharedlib' of makefile '.../network/lib/'ins_net_client.mk' 错误
  • error in invoking target 'client_sharedlib' of makefile 'opt/app/oracle/product/10.2.0/db_1/network/lib/ins_net_client.mk'
  • 在linux下安装oracle时,使用sysctl检查系统参数时出现许多error信息,不知道怎么回事,望高手指点!
  • ERROR about oracle9i install on FC3???
  • Oracle 12c发布简单介绍及官方下载地址
  • 在linux下安装oracle,如何设置让oracle自动启动!也就是让oracle那个服务自动启动,不是手动的
  • oracle 11g最新版官方下载地址
  • 请问su oracle 和su - oracle有什么不同?
  • Oracle 数据库(oracle Database)Select 多表关联查询方式
  • 虚拟机装Oracle R12与Oracle10g
  • Oracle数据库(Oracle Database)体系结构及基本组成介绍
  • Oracle 数据库开发工具 Oracle SQL Developer
  • 如何设置让Oracle SQL Developer显示的时间包含时分秒
  • 编程技术其它 iis7站长之家
  • Oracle 10g和Oracle 11g网格技术介绍
  • SCO unix下安装oracle,但没有光盘,请大家推荐一个oracle下载站点(unix版本的)。谢谢!!!!
  • oracle中如何把表中具有相同值列的多行数据合并成一行
  • 请问大家用oracle数据库, 用import oracle.*;下的东西么? 还是用标准库?
  • Oracle 数据库(oracle Database)性能调优技术详解
  • Linux /$ORACLE_HOME $ORACLE_HOME
  • ORACLE日期相关操作
  • Linux系统下Oracle的启动与Oracle监听的启动
  • ORACLE数据库常用字段数据类型介绍
  • 请问在solaris下安装ORACLE,用root用户和用oracle用户安装有什么区别么?
  • Oracle 12c的九大最新技术特性介绍
  • 网间Oracle的连接,远程连接Oracle服务器??


  • 站内导航:


    特别声明:169IT网站部分信息来自互联网,如果侵犯您的权利,请及时告知,本站将立即删除!

    ©2012-2021,