cancel
Showing results for 
Search instead for 
Did you mean: 

orabrcopy error

former_member269089
Discoverer
0 Kudos

Dear expert,

I'm doing system copy of the following enviroment.

- SAP NetWeaver 7.3 ABAP

- Oracle Database 11.2.0.2

- Red Hat Enterprise Linux 6.0

I have run orabrcopy script, but it stopped for the below error.

Kindly help me for teh solution.


sapvm05:oranw7 53> ./ora_br_copy.sh -generateFiles -forceLogSwitches -targetSid NW7 -password XXXX -listenerPort 1527
+ /usr/lib/jvm/jre-1.6.0-openjdk.x86_64//bin/java -showversion -cp ./.:./orabrcopy.jar:/oracle/NW7/112_64/jdbc/lib/ojdbc5.jar com.sap.inst.lib.app.SecureStartup '' com.sap.inst.orabrcopy.OraBRCopy -oracleHome /oracle/NW7/112_64 -sourceSid NW7 -generateFiles -forceLogSwitches -targetSid NW7 -password XXXX -listenerPort 1527
java version "1.6.0_17"
OpenJDK Runtime Environment (IcedTea6 1.7.4) (rhel-1.21.b17.el6-x86_64)
OpenJDK 64-Bit Server VM (build 14.0-b16, mixed mode)

java.lang.IllegalStateException: Oracle JDBC driver must be loaded
        at com.sap.inst.lib.db.OracleDriver.getUrlConnection(OracleDriver.java:139)
        at com.sap.inst.orabrcopy.OraSourceTask.generateFiles(OraSourceTask.java:213)
        at com.sap.inst.orabrcopy.OraSourceTask.execute(OraSourceTask.java:191)
        at com.sap.inst.orabrcopy.OraSourceTask.run(OraSourceTask.java:157)
        at com.sap.inst.orabrcopy.OraBRCopy.startAppJob(OraBRCopy.java:316)
        at com.sap.inst.lib.app.CommandLineApp.doMain(CommandLineApp.java:111)
        at com.sap.inst.orabrcopy.OraBRCopy.main(OraBRCopy.java:367)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:616)
        at com.sap.inst.lib.app.SecureStartup.startAppMain(SecureStartup.java:153)
        at com.sap.inst.lib.app.SecureStartup.startJavaProcess(SecureStartup.java:83)
        at com.sap.inst.lib.app.SecureStartup.main(SecureStartup.java:252)

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Tetsuya,

Try using j2sdk 1.4.2.

For Linux, it would be IBM JDK.

I remember there is a sapnote guiding where to download it, but sadly it lost.

Thanks

Edited by: Shadowdancer on Aug 4, 2011 9:53 AM

former_member269089
Discoverer
0 Kudos

Thanks for your advice.

I tried with JDK1.4.2, but other error happend.


sapvm05:oranw7 51> setenv JAVA_HOME /usr/lib/jvm/jre-1.4.2-ibm-sap.x86_64/
sapvm05:oranw7 52> ./ora_br_copy.sh -generateFiles -forceLogSwitches -targetSid NW7 -password XXXX -listenerPort 1527
+ /usr/lib/jvm/jre-1.4.2-ibm-sap.x86_64//bin/java -showversion -cp ./.:./orabrcopy.jar:/oracle/NW7/112_64/jdbc/lib/ojdbc5.jar com.sap.inst.lib.app.SecureStartup '' com.sap.inst.orabrcopy.OraBRCopy -oracleHome /oracle/NW7/112_64 -sourceSid NW7 -generateFiles -forceLogSwitches -targetSid NW7 -password XXXX -listenerPort 1527
java version "1.4.2"
Java(TM) 2 Runtime Environment, Standard Edition (build 2.3)
IBM J9 VM (build 2.3, J2RE 1.4.2 IBM J9 2.3 Linux amd64-64 j9vmxa64142ifx-20101119 (JIT enabled)
J9VM - 20101118_68931_LHdSMr
JIT  - 20090210_1447ifx2_r8
GC   - 200902_24)

The java class could not be loaded. java.lang.UnsupportedClassVersionError: (com/sap/inst/lib/app/SecureStartup) bad major version at offset=6

Former Member
0 Kudos

The easiest way is just to do the copy and create the new control file manually.... It's a matter of a couple of minutes.

Kind regards,

Mark

former_member269089
Discoverer
0 Kudos

Thank you for reply.

I understand to manually create init<SID>.ora and control file, but how can I make control.sql ?

Edited by: Tetsuya Kawahara on Aug 4, 2011 4:21 PM

Former Member
0 Kudos

Hi Tetsuya,

To manually create controlfile, do this as ora<sid>:


sqlplus /nolog
connect / as sysdba;
alter database backup controlfile to trace

Then in /oracle/<SID>/saptrace/usertrace find the latest file, there will be entry started with:


STARTUP NOMOUNT
CREATE CONTROLFILE REUSE DATABASE "IE3" NORESETLOGS  ARCHIVELOG

and ended with:


CHARACTER SET UTF8
;

copy and paste those lines to another file e.g cntrl.sql

That is your controlfile-creation script

former_member269089
Discoverer
0 Kudos

Hi,

Thanks a lot !

Regards,

Kawahara

Answers (5)

Answers (5)

carsten_esser
Explorer
0 Kudos

Hi, the workaround in updating the ora_db_copy.bat worked with the path DIR_EXECUTABLE, i.e C:\usr\sap\T00\SYS\exe\run\ojdbc14.jar

Best regards

Carsten

Former Member
0 Kudos

There is now an OSS note that deals with both the JDBC and CLASS12.JAR issue.  Please have a look at OSS note 1786134 here http://service.sap.com/sap/support/notes/1786134

Former Member
0 Kudos

Herve

Thanks. Your workaround , updating the ora_br_copy.sh worked for me. Thanks.

Neval

former_member790525
Discoverer
0 Kudos

Hello,

I had same kind of issue after upgrade our system from NW 7.0 ora10G to NW 7.3 ora11G : I was trying to use last version of orabrcopy, but it doesn't work anymore with a jdbc error.

I have change the line from "ora_br_copy.sh" SAP scripting like that :

#"$JAVA_HOME"/bin/java -showversion -cp "$MIG_HOME/.:$MIG_HOME/orabrcopy.jar:$ORACLE_HOME/jdbc/lib/ojdbc5.jar" com.sap.inst.lib.app.SecureStartup "" com.sap.inst.orabrcopy.OraBRCopy -oracleHome "$ORACLE_HOME" -sourceSid "$ORACLE_SID" "$@"

to :

#"$JAVA_HOME"/bin/java -showversion -cp "$MIG_HOME/.:$MIG_HOME/orabrcopy.jar:$ORACLE_BASE/client/11x_64/instantclient/ojdbc14.jar" com.sap.inst.lib.app.SecureStartup "" com.sap.inst.orabrcopy.OraBRCopy -oracleHome "$ORACLE_HOME" -sourceSid "$ORACLE_SID" "$@"

So I use ojdbc14.jar from Instant client 11G instead of Oracle database library ojdbc5.jar, and It's works.

What I suppose, is that my SAP system is using instantClient 11G library when SAP is started, so It should use the same with orabrcopy.

Hervé.

former_member790525
Discoverer
0 Kudos

In fact you can upload the latest package of orabrcopy wich is located under "SYSTEM COPY TOOLS 7.00"  .......... ORABRCOPY_3-20001410.SAR

In this new script, the JDBC_DRIVER variable is used in the command line, and it's work also.

Hervé COUTEAU

ding_bo
Discoverer
0 Kudos

I met the same problem, and 'ojdbc14.jar' is correct for the script. The control file and pfile were generated successfully.

Thanks for the solution.

Former Member
0 Kudos

hi,

classes12.jar file must exist in the <ORACLE_HOME>/jdbc/lib directory

Loren