Database Journal
MS SQL Oracle DB2 Access MySQL PostgreSQL Sybase PHP SQL Etc SQL Scripts & Samples Links Database Forum

» Database Journal Home
» Database Articles
» Database Tutorials
MS SQL
Oracle
DB2
MS Access
MySQL
» RESOURCES
Database Tools
SQL Scripts & Samples
Links
» Database Forum
» Sitemap
Free Newsletters:
DatabaseDaily  
News Via RSS Feed


follow us on Twitter
Database Journal |DBA Support |SQLCourse |SQLCourse2
 

Featured Database Articles

Oracle

Posted Apr 29, 2003

Getting Control of the Oracle Java Virtual Machine - Page 5

By Marin Komadina

Procedure for Cleaning Up JVM

The JVM installation and un-installation scripts are copied automatically by Oracle during the installation procedure. To remove JVM from database versions 8.1.5 and 8.1.6 we need simply to run the rmjvm.sql deinstallation script.

For database version 8.1.7 this is not enough; we need to execute several steps before removing the JVM:

/$ORACLE_HOME/rdbms/admin/rmrepapi.sql 
/$ORACLE_HOME/oracore/admin/rmxml.sql 
drop trigger JIS$ROLE_TRIGGER$; 
delete from duc$ where owner='SYS' and pack='JIS$INTERCEPTOR$' 
and proc='USER_DROPPED'; 
delete from aurora$startup$classes$ 
where classname='oracle.aurora.mts.http.admin.RegisterService'; 
delete from aurora$dyn$reg; 
/$ORACLE_HOME/javavm/install/rmjvm.sql 

The procedure provided by Oracle, for removing JVM and other Java components has many errors and omissions.

In some versions, the removal scripts are buggy, and in others, the Oracle upgrade and removal documentation does not clarify all of the steps for all possible situations.

Subsequent attempts to re-install will not finish cleanly but rather have multiple failures. If the JVM becomes corrupt, half installed or inconsistent, it should be corrected with the "create or replace java system" command.

create or replace java system; 
* 
ERROR at line 1: 
ORA-03113: end-of-file on communication channel 

If the Java reload process (create or replace java system) doesn`t finish regularly, Oracle recommends several steps for manual Java removal:

  1. restart the database
  2. start a different session that the one the started the database
  3. run initjvmaux.sql
  4. run rmjvm.sql
  5. drop trigger JIS$ROLE_TRIGGER$;
  6. delete from ducs$ where owner='SYS' and pack='JIS$INTERCEPTOR$' and proc='USER_DROPPED';
  7. delete from aurora$startup$classes$ where classname='oracle.aurora.mts.http.admin.RegisterService';
  8. delete from aurora$dyn$reg;
  9. restart the database

To show once more how "buggy" Oracle JVM scripts are, here is a log from the regular JVM upgrade:

ORA-29515: exit called from Java code with status 0

Oracle says: "You need not worry about this message as actually it is not an error.

ORA-29515 is the way in which the javavm reports that the java exit method has been called. In this case, exit is being called intentionally to clear java session state.

You can ignore these harmless errors in 817/8171. This misleading message code is removed in 9i. "

Some more limitations regarding the Java option:

  • initjvm.sql should not be run from the same sqlplus session that started the instance (related to Bug:1335603).
  • for reinstall of all java-related components after executing initjvm.sql script and prior other scripts we should ( drop table JAVA$CLASS$MD5$TABLE; )
  • you can expect to find a few classes that will not compile or classes that are not found (missing); the jar file that the class belongs to needs to be reloaded in the following way (call dbms_java.loadjava ('-force -synonym -grant PUBLIC jis/lib/full_orb.jar jis/lib/servlet.jar)

Some of symptoms you can expect if the Java option is not complete:

a.      ) Shutdown immediate hanging hours

b.      ) Create or replace java system, never finished

c.      ) Java object count get total 6124 java objects

d.      ) Export could not export synonyms

. about to export DBSNMP's tables via Conventional Path ...

. exporting referential integrity constraints

. exporting synonyms

EXP-00008: ORACLE error 904 encountered

ORA-00904: invalid column name

EXP-00000: Export terminated unsuccessfully



Oracle Archives

Comment and Contribute

 


(Maximum characters: 1200). You have characters left.

 

 




Latest Forum Threads
Oracle Forum
Topic By Replies Updated
Oracle Data Mining: Classification jan.hasller 0 July 5th, 07:19 AM
Find duplicates - Unique IDs Lava 5 July 2nd, 08:30 AM
no matching unique or primary key rcanter 1 April 25th, 12:32 PM
Update values of one table based on condition of values in other table using Trigger Gladiator 3 February 29th, 06:01 PM


















Thanks for your registration, follow us on our social networks to keep up-to-date