Online Tutorials & Training Materials | STechies.com
Register Login

Homogenious System Copy Failure - ERROR Connect to database failed

Guest || 13 Apr 2009 1:44 pm || 4

Hi,

I am doing homogeneous System Copy following the exact documentation and CD`s as mentioned in the Documentation and notes.

Note - Oracle Special Installation and Sys Copy Features - Note 659509

and the R3 4.7Installation guide for Solaris and Oracle - Section Oracle Specific Procedure as detailed in the Note. WAS 6.20 Homogeneous System Copy Documentation and the required CD`s

As mentioned in the guide I did rename the control.xml , found the message box "Not Found", cancelled it, did R3Copy, brought the target database up which is OP2 . (Doing a copy from (Source)OP1 to (Target) OP2). Now in the guide it says under section OracleSpecficProcedure. Before you startup R3Setup(In this case SAPINST)to run sapdba -
usyste/ <passwd> -alter_user system/manager and other users like sys/change_on_install and sapr3/sap. I did all of these as well.

It also says in the note 659509 (Oracle Special Installation and Sys Copy Features ) to run oradbusr.sql from the sapinst cd (The CD number 51019679) under /UNIX/COMMON/INSTALL before starting SAPINST again. Then i run this SQL Script as per the note
---------------------

uk-oasdbs002:oraop2 639% cd //oracle/51019679/UNIX/COMMON/INSTALL
uk-oasdbs002:oraop2 640% ls
ALMTTREE DEFAULTR3EHP11_64 R3COPY STARTCI
DBENV.CSH INITSID.DBA SAPENV.CSH STARTCI-EI
DBENV.SH INITSID.ORA SAPENV.SH STARTDI
DBSRC.CSH INSTPFLEI SAPSRC.CSH STARTEI
DBSRC.SH LISTENER.ORA SAPSRC.SH STARTSAPASCS
DEFAULTR3EAIX4_64 ORADBUSR.SQL SPLITSTR.PL TNSNAMES.ORA
DEFAULTR3EAIX_64 PROTOCOL.ORA SQLNET.ORA TOPLEVEL.XML

uk-oasdbs002:oraop2 641% sqlplus /nolog @ORADBUSR.SQL SAPOP1 UNIX OP2 x

(Please see I am using SAPOP1 as the schema owner as I had an error beore ) - Using SAPOP2 gives me an error in the above script.

After this I executed the step insert into OPS$OP2ADM.sapuser values (`SAPOP2`,`SAP`); (as per the note)
Then I restarted the SAPINST and followed from message box "Not Found", pressed OK ,
The error which I am getting is
ee `/sapmnt/OP2/exe/saplicense -R3Setup OP2 "OMBAYXH1" TRACE=2` output
in `/oracle/SAPINST_WORK_DIR/saplicense.log`.
ERROR 2005-01-27 14:35:21
MOS-01012  PROBLEM: `/sapmnt/OP2/exe/saplicense -R3Setup OP2 "OMBAYXH1"
TRACE=2` returned with `254` which is not a defined as a success code.
ERROR 2005-01-27 14:35:21
FJS-00012  Error when executing script.

In this log there is not much info

uk-oasdbs002:op2adm 30% cat /oracle/SAPINST_WORK_DIR/saplicense.log
Thu Jan 27 14:35:21 2005
MtxInit: 0 0 0

Again if i run this command as standalone as op2adm

/sapmnt/OP2/exe/saplicense -R3Setup OP2 "OMBAYXH1" TRACE=2

Felow is the dev_slic which i get

uk-oasdbs002:oraop2 58% cat dev_slic
---------------------------------------------------
trc file: "dev_slic", trc level: 2, release: "620"
---------------------------------------------------
SlicIGetDate: <20050127>
SlicPwForR3Setup: calc password out of <op220050127fjawfnltl>
SlicIGetDate: <20050127>
SlicSapInstall: sysname: >OP2< connect: >1< rollback: >1<
SlicIDbLock: first call to SlicIDbLock: initialize Mutex
db_con_init called
create_con (con_name=R/3)
Loading DB library `/usr/sap/OP2/SYS/exe/run/dboraslib.so` ...
load shared library (/usr/sap/OP2/SYS/exe/run/dboraslib.so), hdl 0
Library `/usr/sap/OP2/SYS/exe/run/dboraslib.so` loaded
function DbSlExpFuns loaded from library /usr/sap/OP2/SYS/exe/run/dboraslib.so
Version of `/usr/sap/OP2/SYS/exe/run/dboraslib.so` is "620.02", patchlevel (0.1603)
function dsql_db_init loaded from library /usr/sap/OP2/SYS/exe/run/dboraslib.so
function dbdd_exp_funs loaded from library
/usr/sap/OP2/SYS/exe/run/dboraslib.so
New connection 0 created
0: name = R/3, con_id = -000000001 state = DISCONNECTED, perm = YES, reco = NO
db_con_connect (con_name=R/3)
find_con found the following connection for reuse:
0: name = R/3, con_id = 000000000 state = DISCONNECTED, perm = YES, reco = NO
Got ORACLE_HOME=/oracle/OP2/920_64 from environment
-->oci_initialize
*** ERROR => OCI-call `OCIInitialize` failed: rc = -1 [dboci.c      1823]
*** ERROR => OCI-call `OCIErrorGet` failed: rc = -2 [dboci.c      1723]
Got ORACLE_HOME=/oracle/OP2/920_64 from environment
-->oci_initialize
*** ERROR => OCI-call `OCIInitialize` failed: rc = -1 [dboci.c      1823]
*** ERROR => OCI-call `OCIErrorGet` failed: rc = -2 [dboci.c      1723]

*****************************************************************************
*
*  ERROR       Connect to database failed
*
*  TIME        Thu Jan 27 15:05:38 2005
*  RELEASE     620
*  COMPONENT   SLIC
*  VERSION     300
*  RC          99
*  MODULE      slicdb.c
*  LINE        150
*  DETAIL      DbSlConnect failed with return code 99
*              SQL-ERROR -1 (check DB manual for explanation)
*  COUNTER     1
*
*****************************************************************************
Please advise, I cannot run the System Copy any further and I am little stuck in this.


Comments

  • 13 Apr 2009 1:44 pm

    This is a know problem. Review note 534765:

    Symptom

    1. During connect of r3trans -d you get the error

    2EETW000 sap_dext called with msgnr "2":
    2EETW000 db call info
    2EETW000 function: db_ntab
    2EETW000 fcode: NT_RDTDESCR
    2EETW000 tabname: TADIR
    2EETW000 len: 5
    2EETW000 key: TADIR
    2EETW000 retcode: 2
    r3trans finished (0012).

    [...]
    Regards

  • 13 Apr 2009 1:44 pm
    Attached please find a document describing the copy procedure.(found on the internet)
  • 13 Apr 2009 1:44 pm

    This is R3trans version 6.09 (release 620 - 16.12.03 - 11:19:00).
    2EETW000 sap_dext called with msgnr "2":
    2EETW000 ---- db call info ----
    2EETW000 function:   db_ntab
    2EETW000 fcode:      NT_RDTDESCR
    2EETW000 tabname:    TADIR
    2EETW000 len:        5
    2EETW000 key:        TADIR
    2EETW000 retcode:    2
    R3trans finished (0012).
    ----------------------------------
    small jist of trans.log
     
    4 ETW000  [dev trc     ,00000]  Now I`m connected to ORACLE                         2656  0.125475
    4 ETW000  [dev trc     ,00000]  Got SAPOP2`s password from OPS$-user                1876  0.127351
    4 ETW000  [dev trc     ,00000]  Disconnecting from connection 0 ...                   42  0.127393
    4 ETW000  [dev trc     ,00000]  Rolling back transaction ...                          57  0.127450
    4 ETW000  [dev
    trc     ,00000]  Closing user session (con_hdl=0,svchp=10105ca88,usrhp=1010a28a8)
    4 ETW000                                                                             460  0.127910
    4 ETW000  [dev trc     ,00000]  Now I`m disconnected from ORACLE                    1247  0.129157
    4 ETW000  [dev trc     ,00000]  Connecting as SAPOP2/@OP2 on connection 0 ...
    4
    ETW000                                                                              89  0.129246
    4 ETW000  [dev trc     ,00000]  Assigning username to user session 1010a28a8          28  0.129274
    4 ETW000  [dev trc     ,00000]  Assigning password to user session 1010a28a8          33  0.129307
    4 ETW000  [dev trc     ,00000]  Starting user session
    (con_hdl=0,svchp=10105ca88,srvhp=10105c778,usrhp=1010a28a8)
    4 ETW000                                                                              43  0.129350
    4 ETW000  [dev trc     ,00000]  Assigning user session 1010a28a8 to service context 10105ca88
    4
    ETW000                                                                            5292  0.134642
    4 ETW000  [dev trc     ,00000]  Now I`m connected to ORACLE                          727  0.135369
    4 ETW000  [dev trc     ,00000]  Database NLS settings: AMERICAN_AMERICA.WE8DEC       997  0.136366
    4 ETW000  [dev trc     ,00000]  Database instance OP2 is
    running on uk-oasdbs002 with ORACLE version 9.2.0.5.0 since 20050127
    4 ETW000                                                                             941  0.137307
    4 ETW000  [dev trc     ,00000]  Connection 0 opened                                 1692  0.138999
    4 ETW000  [dblink      ,01292]  ***LOG BZA=>table SVERS      does not exist on
    database [dblink#1 @ 1292]
    4 ETW000                                                                           10432  0.149431
    4 ETW000  [dev trc     ,00000]  NTAB: SELECT COMPCNT FROM DDNTT FAILED              1464  0.150895
    4 ETW000  [dev trc     ,00000]  NTAB: SELECT VERSION FROM DDNTT FAILED               826  0.151721
    4 ETW000  [dbntab.c    ,00000]  *** ERROR => NTAB:
    SELECT VERSION/DBASE FROM DDNTT FAILED
    4 ETW000                                                                             781  0.152502
    4 ETW000  [dbntab      ,01270]  ***LOG BZY=>unexpected return code 103        calling NTAB       [dbntab#15 @ 12709]
    4
    ETW000                                                                              84  0.152586
    4 ETW000  [dev trc     ,00000]  NTAB: standalone processing                          196  0.152782
    4 ETW000  [dev trc     ,00000]  NTAB: read
    profile                                    75  0.152857
    4 ETW000  [dev trc     ,00000]  NTAB: rsdb/ntab/entrycount 1000.                      30  0.152887
    4 ETW000  [dev trc     ,00000]  NTAB: rsdb/ntab/ftabsize 500.                         25  0.152912
    4 ETW000  [dev trc     ,00000]  NTAB: rsdb/ntab/irbdsize 100.                         24  0.152936
    4
    ETW000  [dev trc     ,00000]  NTAB: rsdb/ntab/sntabsize 100.                        23  0.152959
    4 ETW000  [dev trc     ,00000]  NTAB: compute_hash_card: 2003.                       159  0.153118
    4 ETW000  [dev trc     ,00000]  NTAB: maxcnt 1000.                                    38  0.153156
    4 ETW000  [dev trc     ,00000]  NTAB: hfactor
    2003.                                   25  0.153181
    4 ETW000  [dev trc     ,00000]  NTAB: mem_protocol_size 104                          139  0.153320
    4 ETW000  [dev trc     ,00000]  NTAB: hdr_backpack_offset 0                           26  0.153346

    -- From the output it says it tries to read the tables DDNTT , SVERS but SAPOP2 schema doesnt contain any tables. As a matter of fact when I copied the database from OP1 as expected there will not be any SAPOP2. During the installation this user got created. Then i corrected the privs as it did not had any create session and gave all the necessary rights.
    But this users doesnt have any tables. The schema is SAPOP1 which is present being carried over from the Source system.
    -------
    I have got the following in the environment
    dbms_type=ORA
    dbs_ora_tnsname=OP2
    dbs_ora_schema=SAPOP2
    ORACLE_PSRV=OP2
    ORACLE_SID=OP2
    DB_SID=OP2
    ORACLE_HOME=/oracle/OP2/920_64
    ORACLE_BASE=/oracle
    -----------------------------
     
    Do I need to make the dbs_ora_schema as SAPOP1 . Here.
    As if i do that R3trans -d is successull

  • 13 Apr 2009 1:44 pm

    try to run R3trans -d and find from the R3trans.log from the current directory to see if there`re any log inf., compared with the log in a good system after you run R3trans -d to find out at what step sap can`t connect to dbs.,  it is probably due to the environment variable dbs_ora_schema should be OP2, instead of OP1,  also , verify that ops$op2adm is identified externally with the connect, resource and sapdba privilege, and initialize the ops$op2adm with sapdba, option M and then D.