Skip to main content

Featured

Missing Java Classes - Oracle Database

 Recently in out UAT database our DBA had found that the component JAVAVM (JServer JAVA Virtual Machine) is invalid, and hence he did the JVM reload. One thing he forgot was that the impact of JVM reload on existing JAVA objects in the database. Yes, all the java classes/objects got dropped due to the sudden JVM reload.   Ours is not a standalone database it has various applications running on top of using several java classes, and hence all our applications stopped working. So after a lot of trial and errors, we figured out the complete steps to fix our issue. Query to check the java objects in the database: select owner , count(*) from dba_objects where OBJECT_TYPE like '%JAVA%' group by owner;   Oracle EBusiness Suite Application - APPS                a)        Take a backup of $AD_TOP/admin/driver/adldjava.drv and replace all loadjava commands with below lines loadjava csf java...

Import Performance Improvement

How to increase the speed of Import in Oracle


Scenario

We need to import a schema frequently which is of nearly 30 GB , While importing the schema we found that it is trying to create indexes for a long time.

Our Import took nearly 6 hours in which index creation alone took 5 hours.

Solution:

  • Create a directory in both source and destination instances.
  1.  Command:
  2.      CREATE OR REPLACE DIRECTORY EXP_IMP AS '/u01/app/oracle/dump';
  3.       grant read,write on directory EXP_IMP to public;
  •  Export the schema
  1.      Command: 
  2.      expdp system/manager directory=EXP_IMP schemas=SCOTT dumpfile=SCOTT_exp.dmp     logfile=SCOTT_exp.log 
  • Transfer the dumpfile to the Target server.
  • Get the index script from the dumpfile
  1.    Command :
  2.     impdp system/manager directory=EXP_IMP dumpfile=SCOTT_exp.dmp include=INDEX exclude=STATISTICS  sqlfile=SCOTT_index.sql logfile=SCOTT_imp_index.log
  • Import the schema excluding index and statistics.
  1.    Command:
  2.     impdp system/manager directory=EXP_IMP dumpfile=SCOTT_exp.dmp  exclude=STATISTICS,INDEX  logfile=SCOTT_imp.log
  • After importing the schema execute the index file.
  1.    Edit the sqlfile to change the clause "Parallel 1" to "Parallel 16" or higher value depending on your system load.
  2. sqlplus scott/tiger @SCOTT_index.sql

To our surprise the whole process completed in 2 hours. We saved 4 hours!!!!!!!!!!!!


Comments

Popular Posts