cancel
Showing results for 
Search instead for 
Did you mean: 

Problem after SQL restore

Former Member
0 Kudos

Hi,

We have restored and ECC system from a backup from another system with the same SID. We are using windows server 2012 using SQL server 2012 as DB .

Restore finished sucessfully and we can connect to the DB from the SQL server studio but SAP is not starting .

We have done the R3trans -x and it's working but when we execute R3trans -d we have this on the trans.log:

4 ETW000  [dbntab  ,00000]  ***LOG BZY=>unexpected return code 103 calling NTAB                   49  0.076166
4 ETW000  [ dev trc,00000]  NTAB: db_ntab(): init_ntab failed, returning 2                        52  0.076218
4 ETW000  [ dev trc,00000]  NTAB: SELECT COMPCNT, UNICODELG FROM XXXXT WHERE TABNAME = 'SVERS'...
4 ETW000                                                                                              32  0.076250
4 ETW000  [ dev trc,00000]  db_con_test_and_open: 3 open cursors (delta=1)                        34  0.076284
4 ETW000  [ dev trc,00000]  db_con_check_dirty: 3 open cursors, tx = NO , bc = NO                 18  0.076302
4 ETW000  [ dev trc,00000]  db_con_check_dirty: db_con_dirty = YES                                16  0.076318
4 ETW000  [ dev trc,00000]  ERROR: -1 in function StartSelect (execute) [line 14698]             880  0.077198
4 ETW000  [ dev trc,00000]  (208) [42S02] [Microsoft][SQL Server Native Client 11.0][SQL Server]Invalid object name 'XXXXT'.
4 ETW000                                                                                              68  0.077266
4 ETW000  [ dev trc,00000]  Error 103 (dbcode 208) in StartSelect                                 33  0.077299
4 ETW000  [ dev trc,00000]  StartSelect: stmt of NULL_STMTID                                      22  0.077321
4 ETW000  [ dev trc,00000]  SELECT COMPCNT, UNICODELG FROM "XXXXT" WHERE TABNAME = 'SVERS'        28  0.077349
4 ETW000                    /* R3::0 T:XXXXT
4 ETW000  [ dev trc,00000]   */                                                                   24  0.077373
4 ETW000  [ dev trc,00000]  NTAB: SELECT COMPCNT, UNICODELG FROM XXXXT WHERE TABNAME = 'SVERS' FAILED
4 ETW000                                                                                              37  0.077410
4 ETW000  [ dev trc,00000]  NTAB: SELECT VERSION FROM XXXXT WHERE TABNAME = 'SVERS'...            20  0.077430
4 ETW000  [ dev trc,00000]  db_con_test_and_open: 4 open cursors (delta=1)                        32  0.077462
4 ETW000  [ dev trc,00000]  db_con_check_dirty: 4 open cursors, tx = NO , bc = NO                 18  0.077480
4 ETW000  [ dev trc,00000]  db_con_check_dirty: db_con_dirty = YES                                16  0.077496
4 ETW000  [ dev trc,00000]  ERROR: -1 in function StartSelect (execute) [line 14698]             925  0.078421
4 ETW000  [ dev trc,00000]  (208) [42S02] [Microsoft][SQL Server Native Client 11.0][SQL Server]Invalid object name 'XXXXT'.
4 ETW000                                                                                              62  0.078483
4 ETW000  [ dev trc,00000]  Error 103 (dbcode 208) in StartSelect                                 58  0.078541
4 ETW000  [ dev trc,00000]  StartSelect: stmt of NULL_STMTID                                      25  0.078566
4 ETW000  [ dev trc,00000]  SELECT VERSION FROM "XXXXT" WHERE TABNAME = 'SVERS'                   27  0.078593
4 ETW000                    /* R3::0 T:XXXXT */
4 ETW000  [dbntab.c,00000]  *** ERROR => NTAB: SELECT VERSION FROM XXXXT WHERE TABNAME = 'SVERS' FAILED
4 ETW000                                                                                              55  0.078648
4 ETW000  [dbntab  ,00000]  ***LOG BZY=>unexpected return code 103 calling NTAB                   34  0.078682
4 ETW000  [ dev trc,00000]  NTAB: db_ntab(): init_ntab failed, returning 2                        30  0.078712

2EETW000 sap_dext called with msgnr "2":

2EETW000 ---- db call info ----

2EETW000 function:   db_ntab

2EETW000 fcode:  NT_RDTDESCR
2EETW000 tabname:TADIR

2EETW000 len (char): 5

2EETW000 key:    TADIR
2EETW000 retcode:2
4 ETW000  [ dev trc,00000]  db_con_rollback (con_da={R/3,0,0},th_rollback=1,tx=0)               8086  0.086798
4 ETW000  [ dev trc,00000]  db_con_check_dirty: db_con_dirty = NO

We have set up these environment variables :

ICM log:

*** ICM up and operational (pid: 2196, HTTP: -, HTTPS: -) ***

Shutdown ICM server ...............

*** ICM shutdown completed (pid: 2196) ***

rslgwr1(21): Searching for overlap point in pre-existing SysLog file...

*** DISPATCHER EMERGENCY SHUTDOWN => DpWpCheck: no more work processes

Created shared memory for profile parameters

Please, could someone help us?

Thanks a lot , sapera

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member185239
Active Contributor
0 Kudos

Hi Sapera,

Can you paste the dev_ms and dev_w0 logs.

With Regards

Ashutosh Chaturvedi

Former Member
0 Kudos

Hi Sapera,

What restore method did you use (backup/restore homogenous copy)? Is source system same as target OS and DB version? Is the Hostname and IP same as source? Did you use SWPM for system copy? Are the SAP services running at OS level? If everything is perfect and no issues, then analyze the work directory. Check the Hosts and services file at windows level for any wrong entry or copy from source. Did you copy the profile parameters from source? Is there any entry that needs to be edited in profile? I see that you have already updated the environment variables same as source? Please check all these and provide the developer trace for the processes from SAP MMC. Also relevant logs from work directory. Also is the source system shutdown (with same hostname and IP)?

Thanks,

Kavitha Rajan.

Former Member
0 Kudos

Hi,

I forgot to add the dbsl_w1 output:

2:35:21.148 [-1] ExecuteAndFlush:use [DR1]

12:35:21.148 [-1] dbsl_rc 0 dbcount -1

12:35:21.148 [-1] Driver: sqlncli11.dll Driver release: 11.00.3393

12:35:21.148 [-1] ExecuteAndFlush:if user_name() != 'SAPDR1' execute as login = suser_sname(suser_sid('SAPDR1')) with no revert

12:35:21.148 [-1] ERROR: -1 in function ExecuteAndFlush (SQLExecDirect) [line 7451]

12:35:21.148 [-1] (102) [42000] [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'execute.'.

12:35:21.148 [-1] dbsl_rc 99 dbcount 0

12:35:21.148 [-1] <if user_name() != 'SAPDR1' execute as login = suser_sname(suser_sid('SAPDR1')) with no revert> failed -- connect terminated

Thanks a lot, sapera

Sriram2009
Active Contributor
0 Kudos

Hello SAPERA

Where your are restore the DB & ECC system the host name is same from where your are taken the backup?

I think you have to take the server in the private environment, change the Server name same as where your are taken the backup and try to start the SAP system. If your are having still the same repair schema from the SAP note

1294762 - SCHEMA4SAP.VBS

BR

SS

Former Member
0 Kudos

Hi,

After using the scrip attached to the note, R3trans is fine but sap continues with working.

This is the output of the dev_dips:

DpWpLock: locked wp_adm[18].mutex

DpWpUnlock: unlocked wp_adm[18].mutex

DpWpLock: locked wp_adm[19].mutex

DpWpUnlock: unlocked wp_adm[19].mutex

DpWpLock: locked wp_adm[20].mutex

DpWpUnlock: unlocked wp_adm[20].mutex

DpMsServerDown: wakeup waiting sessions

NiICloseHandle: shutdown and close hdl 17/sock 820

NiBufIClose: clear extension for hdl 17

MsIDetach: detach MS-system (DRECCRF / 3901)

DpHalt: cleanup EM

EsCleanup( )

EsCleanup ....

EmCleanup() -> 0

Es2Cleanup: Cleanup ES2

***LOG Q05=> DpHalt, DPStop ( 4596) [dpInit.c     3550]

DpHalt: Good Bye .....

Some other idea?

Thanks a lot, sapera

Sriram2009
Active Contributor
0 Kudos

Hi

Just do the full system restart and then try again update the latest log.

BR

SS

Former Member
0 Kudos

Hi,

We have restarted the server and same issue:

iBufSend starting

NiIWrite: hdl 17 sent data (wrt=110,pac=1,MESG_IO)

<<< NiBufISelUpdate: hdl 17(0, SAP_O_K)

MsINiWrite: sent 110 bytes

MsIDetach: send logout to msg_server (DRECCRF / 3901)

MsIDetach: call exit function

DpMsShutdownHook called

NiBufISelRemove: remove hdl 17 from set0

<<< NiBufISelUpdate: hdl 17(0, SAP_O_K)

SiSelNRemove: removed sock 816

NiSelIRemove: removed hdl 17

DpDelSocketInfo: del info for nihdl 17 (pos/type=2/4)

DpMBufClearGlobalHighLoadCounter: reset global load flags

MBUF state OFF

AdGetSelfIdentRecord: >                                                                           <

AdCvtRecToExt: opcode 60 (AD_SELFIDENT), ser 0, ex 0, errno 0

AdCallRegisteredCvtToExt: opcode AD_SELFIDENT (60)

AdCallRegisteredCvtToExt: opcode AD_SELFIDENT (60) call 00007FF700B50600

AdCallRegisteredCvtToExt: opcode AD_SELFIDENT (60) exit rc=SAP_O_K

AdCvtRecToExt: opcode 40 (AD_MSBUF), ser 0, ex 0, errno 0

AdCallRegisteredCvtToExt: opcode AD_MSBUF (40)

AdCallRegisteredCvtToExt: opcode AD_MSBUF (40) call 00007FF700B512C0

AdCallRegisteredCvtToExt: opcode AD_MSBUF (40) exit rc=SAP_O_K

AdCvtRecToExt: opcode 40 (AD_MSBUF), ser 0, ex 0, errno 0

AdCallRegisteredCvtToExt: opcode AD_MSBUF (40)

AdCallRegisteredCvtToExt: opcode AD_MSBUF (40) call 00007FF700B512C0

AdCallRegisteredCvtToExt: opcode AD_MSBUF (40) exit rc=SAP_O_K

DpRqCreate: creating REQ_HANDLER_MSADM request (rq_id 3504, slot 14)

DpCaLockBlk: locked ca_blk 0

DpRqSendRequest: REQ_HANDLER_MSADM (rq_id 3504) from DISP to local DISP

DpCaGiveUpOwnerOfBlk: give up ownership of ca_blk 0

rq_id 3504

-OUT- ca_blk    0            len       348        

-OUT- reqHdlId  REQ_HANDLER_MSADM

-OUT- sender address:

-OUT- type      LOCAL

-OUT- agentType DISP        

-OUT- receiver address:

-OUT- type      LOCAL

-OUT- agentType DISP        

RqQAddRequest: Add request rq_id 3504 (NOWP) to queue <DispatcherQueue> in slot 0 at the end

Dump of queue <DispatcherQueue> in slot 0 (2 requests, in use, port=53379):

Thu May 28 14:39:33 2015

  -1 <-    4 (rq_id 3502, NOWP,       REQ_HANDLER_ICMAN_OPCODE) ->    5

   4 <-    5 (rq_id 3504, NOWP,              REQ_HANDLER_MSADM) ->   -1

RqQQueueNotifySelectableHandleAsync: Reuse NI connection for queue <DispatcherQueue> in slot 0 on port 53379 (10026)

RqQQueueNotifySelectableHandleAsync: Signal selectable handle for queue <DispatcherQueue> in slot 0 on port 53379 (id=7)

NiDgHdlSend: hdl 25 sent 1 of 1 bytes to 127.0.0.1:53379

RqQQueueGetNumberOfRequests: Queue <DispatcherQueue> in slot 0 contains 2 requests of type NOWP

DpRqPutIntoQueue: put request into DISP queue (workerType 0, prio LOW, rq_id 3504), queue has 2 requests

DpRqFree: freeing REQ_HANDLER_MSADM request (rq_id 3504, slot 14)

DpMBufTypeMod: MBUF component DOWN (event=MBUF_DPEVT_DOWN)

DpMsServerDown: send delayed handshakes

DpWpSendHandShakeToAllWaiting (wakeupInfo=1)

DpWpLock: locked wp_adm[0].mutex

DpWpUnlock: unlocked wp_adm[0].mutex

DpWpLock: locked wp_adm[1].mutex

DpWpUnlock: unlocked wp_adm[1].mutex

DpWpLock: locked wp_adm[2].mutex

DpWpUnlock: unlocked wp_adm[2].mutex

DpWpLock: locked wp_adm[3].mutex

DpWpUnlock: unlocked wp_adm[3].mutex

DpWpLock: locked wp_adm[4].mutex

DpWpUnlock: unlocked wp_adm[4].mutex

DpWpLock: locked wp_adm[5].mutex

DpWpUnlock: unlocked wp_adm[5].mutex

DpWpLock: locked wp_adm[6].mutex

DpWpUnlock: unlocked wp_adm[6].mutex

DpWpLock: locked wp_adm[7].mutex

DpWpUnlock: unlocked wp_adm[7].mutex

DpWpLock: locked wp_adm[8].mutex

DpWpUnlock: unlocked wp_adm[8].mutex

DpWpLock: locked wp_adm[9].mutex

DpWpUnlock: unlocked wp_adm[9].mutex

DpWpLock: locked wp_adm[10].mutex

DpWpUnlock: unlocked wp_adm[10].mutex

DpWpLock: locked wp_adm[11].mutex

DpWpUnlock: unlocked wp_adm[11].mutex

DpWpLock: locked wp_adm[12].mutex

DpWpUnlock: unlocked wp_adm[12].mutex

DpWpLock: locked wp_adm[13].mutex

DpWpUnlock: unlocked wp_adm[13].mutex

DpWpLock: locked wp_adm[14].mutex

Thu May 28 14:39:33 2015

DpWpUnlock: unlocked wp_adm[14].mutex

DpWpLock: locked wp_adm[15].mutex

DpWpUnlock: unlocked wp_adm[15].mutex

DpWpLock: locked wp_adm[16].mutex

DpWpUnlock: unlocked wp_adm[16].mutex

DpWpLock: locked wp_adm[17].mutex

DpWpUnlock: unlocked wp_adm[17].mutex

DpWpLock: locked wp_adm[18].mutex

DpWpUnlock: unlocked wp_adm[18].mutex

DpWpLock: locked wp_adm[19].mutex

DpWpUnlock: unlocked wp_adm[19].mutex

DpWpLock: locked wp_adm[20].mutex

DpWpUnlock: unlocked wp_adm[20].mutex

DpMsServerDown: wakeup waiting sessions

NiICloseHandle: shutdown and close hdl 17/sock 816

NiBufIClose: clear extension for hdl 17

MsIDetach: detach MS-system (DRECCRF / 3901)

DpHalt: cleanup EM

EsCleanup( )

EsCleanup ....

EmCleanup() -> 0

Es2Cleanup: Cleanup ES2

***LOG Q05=> DpHalt, DPStop ( 3972) [dpInit.c     3550]

DpHalt: Good Bye .....

Any other idea?

Thanks a lot, Sapera