DBSNAPSHOT restore

aixlogician

Active Newcomer
Joined
Feb 19, 2014
Messages
14
Reaction score
0
Points
0
PREDATAR Control23

Hello All,
I am trying to restore dbsnapshot we took on one of our hard drive (xxxx.dss format). When I try to restore it on our TEST DR server it is giving me error as below

We created FILE devclass on our PROD TSM server, took the snapshot on this newly created FILE devclass.
On our DR server ran through the install and db2icfgx, created new FILE devclass and then I ran the command
Code:
dsmserv db restore todate=08/28/2014 totime=12:34:30
Also I tried
Code:
dsmserv db restore

Error:
Code:
c:\Program Files\Tivoli\TSM\server>dsmserv restore db todate=08/28/2014 totime=1
2:34:30
ANR7800I DSMSERV generated at 10:55:11 on May 23 2013.

Tivoli Storage Manager for Windows

Version 6, Release 3, Level 4.000


Licensed Materials - Property of IBM


(C) Copyright IBM Corporation 1990, 2011.
All rights reserved.
U.S. Government Users Restricted Rights - Use, duplication or disclosure
restricted by GSA ADP Schedule Contract with IBM Corporation.


ANR0900I Processing options file C:\Program Files\Tivoli\TSM\SERVER1\dsmserv.o-
pt.
ANR4726I The ICC support module has been loaded.
ANR1636W The server machine GUID changed: old value (), new value (d3.80.c2.51-
.35.0f.11.e4.8f.20.28.92.4a.36.c7.ee).
ANR7808W Sun Microsystems Library Attach module libacs.dll is not available
from the system.
ANR8200I TCP/IP Version 4 driver ready for connection with clients on port
1500.
ANR4634I Starting point-in-time database restore to date 08/28/2014 12:34:30.
ANR4593E Restore database unable to find eligible candidate to use for
processing.
[B]ANR4602E No volumes found for TODATE 08/28/2014 12:34:30.
[/B]

Can anyone help me where I am going wrong and how to restore from DB snap?

Here are my volhost.dat and devconf.dat files on DR server

VOLHIST.DAT
Code:
*********************************************************************************************************
* 
*                                     Sequential Volume Usage History
*                                       Updated 09/05/2014 12:22:36
* 
*********************************************************************************************************
  
 Operation Date/Time:   2014/08/28 12:34:30
 
 Volume Type:  DBSNAPSHOT
* Location for volume E:\
 Volume Name:  "E:\09247270.dss"
 Backup Series:       1
 Backup Op:       0
 Volume Seq:   1
  Device Class Name:  FILE
**************************************************

DEVCONF.DAT
Code:
/* Device Configuration */
DEFINE DEVCLASS FILE DEVT=FILE FORMAT=DRIVE MAXCAP=246415360K MOUNTL=20 DIR="E:\" SHARE=NO
SET SERVERNAME CBTSMLAB01
DEFINE LIBRARY LTOLIB LIBTYPE=MANUAL AUTOLABEL=NO RESETDRIVE=NO
SERVERBACKUPNODEID 1

Thanks in advance.
 
Last edited:
PREDATAR Control23

Thanks marclant!
After adding source as dbsnapshot I am getting the below error

Code:
c:\Program Files\Tivoli\TSM\server>dsmserv restore db source=dbsnapshot todate=0
8/28/2014 totime=12:34:30
ANR7800I DSMSERV generated at 10:55:11 on May 23 2013.

Tivoli Storage Manager for Windows

Version 6, Release 3, Level 4.000


Licensed Materials - Property of IBM


(C) Copyright IBM Corporation 1990, 2011.
All rights reserved.
U.S. Government Users Restricted Rights - Use, duplication or disclosure
restricted by GSA ADP Schedule Contract with IBM Corporation.


ANR0900I Processing options file C:\Program Files\Tivoli\TSM\SERVER1\dsmserv.o-
pt.
ANR4726I The ICC support module has been loaded.
ANR1636W The server machine GUID changed: old value (), new value (d3.80.c2.51-
.35.0f.11.e4.8f.20.28.92.4a.36.c7.ee).
ANR7808W Sun Microsystems Library Attach module libacs.dll is not available
from the system.
ANR8200I TCP/IP Version 4 driver ready for connection with clients on port
1500.
ANR4916I Starting point-in-time database restore snapshot to date 08/28/2014
23:59:59.
ANR4591I Selected backup series 1 from 08/28/2014 and 12:34:30 as best
candidate available for restore database processing.
ANR4592I Restore database backup series 1 includes eligible operation 0 with
volume E:\09247270.dss having sequence 1 and using device class FILE.
ANR4596E Restore database is unable to validate the selected database backup
for series 1 and operation 0 against the actual data from the database backup
stream.
[B]ANR4602E No volumes found for TODATE 08/28/2014 12:34:30.[/B]
 
PREDATAR Control23

Hi,

is the TSM server version used to create the DB Snapshot (the source server) the same as the server of the DR test machine? (are both 6.3.4.0?)

Harry
 
PREDATAR Control23

ANR4596E is because the volume sequence is not valid. Looks like you modified the volhist because the starting sequence is always 10001, and you have 1.

This is likely caused by not having all the necessary volumes available and specified in the volume history file. Or this is caused by having the wrong volume designated with sequence 10001. If a volume in the volume history file for this backup series and operation is assigned 10001, try assigning a different volume as sequence 10001. The volume assigned sequence 10001 is expected to have the self-describing validation information and signatures that are used by the restore processing for validation of a given operation for a backup series. If this information is not found or correct, this would result in a restore failure.
source: http://www-01.ibm.com/support/knowl...ANR4596E.html?cp=SSGSG7_6.3.0/4-0-17-1-1-3426


In the volhist, use:
Code:
Volume Seq:   10001
 
PREDATAR Control23

Thankyou Guys!

Let me change and redo it. I will post you guys with latest updates.

Thanks again.
 
PREDATAR Control23

Update:
I copied the actual volhist file and it started the restore, it was all well but after an hour into restore it gave me below error
Code:
ANR0541W Retrieve or restore failed for session 1 for node $$_TSMDBMGR_$$
(DB2/NT64) - error on input storage device.

I am thinking the disk is bad and I have initiated the scan for bad sectors on the disk.

My DB size is pretty fat sitting around 240GB.

@Harry_Redl, my actual and DR TSM version are 6.3.1 and 6.3.4, so they are both 6.3.
 
PREDATAR Control23

Update:
I copied the actual volhist file and it started the restore, it was all well but after an hour into restore it gave me below error
Code:
ANR0541W Retrieve or restore failed for session 1 for node $$_TSMDBMGR_$$
(DB2/NT64) - error on input storage device.

I am thinking the disk is bad and I have initiated the scan for bad sectors on the disk.

My DB size is pretty fat sitting around 240GB.

@Harry_Redl, my actual and DR TSM version are 6.3.1 and 6.3.4, so they are both 6.3.
You are right with a possible problem with the disk as per ANR0541W -> http://www-01.ibm.com/support/knowl...W.html?cp=SSGSG7_6.3.0/4-0-17-1-1-417&lang=en

Check the Windows Event Viewer in case there may be errors with that volume. It's possible the file is corrupt too, in which case you could recopy it.
 
PREDATAR Control23

Thankyou much guys!
I am in the process of copying the tsmdb to another internal disk. If this does not work, then I will trigger a new snapshot tomorrow on another disk and try to restore the DB.

Again thanks for all the help.

I will keep you posted as I progress.
 
PREDATAR Control23

Hi I was able to restore the DB,
But I am getting this error
Code:
C:\Program Files\Tivoli\TSM\server>dsmserv
ANR7800I DSMSERV generated at 10:55:11 on May 23 2013.

Tivoli Storage Manager for Windows

Version 6, Release 3, Level 4.000


Licensed Materials - Property of IBM


(C) Copyright IBM Corporation 1990, 2011.
All rights reserved.
U.S. Government Users Restricted Rights - Use, duplication or disclosure
restricted by GSA ADP Schedule Contract with IBM Corporation.


ANR0900I Processing options file C:\Program Files\Tivoli\TSM\SERVER1\dsmserv.o-
pt.
ANR4726I The ICC support module has been loaded.
ANR0990I Server restart-recovery in progress.
ANR0298S Authority is insufficient to access the database.
ANR0298S Authority is insufficient to access the database.
ANR9999D_0737318079 tbSQLExecuteToStrings(tbnsql.c:1263) Thread<0>: Unexpected
rc 1040 from tbSQLExecuteSelect.
ANR9999D Thread<0> issued message 9999 from:
ANR9999D Thread<0>  000007FEEAD52C69 OutDiagToCons()+159
ANR9999D Thread<0>  000007FEEAD4C62A outDiagfExt()+11a
ANR9999D Thread<0>  000007FEEAAEB3F8 tbSQLExecuteToStrings()+128
ANR9999D Thread<0>  000007FEEAB069E8 RdbGetRegValues()+858
ANR9999D Thread<0>  000007FEEAB0F2C7 RdbCrossCheckDb2Level()+97
ANR9999D Thread<0>  000007FEEAA78CA8 dbiInit()+1b8
ANR9999D Thread<0>  000007FEEA50D59D AdmServerMonitorThread()+73d
ANR9999D Thread<0>  000007FEEA50ED2B admStartServer()+cb
ANR9999D Thread<0>  000007FEEA4F3474 adsmMain()+e84
ANR9999D Thread<0>  000000013F0F111B main()+9b dsmserv.c:241
ANR9999D Thread<0>  000000013F0F28DA __tmainCRTStartup()+11a crtexe.c:555
ANR9999D Thread<0>  00000000771B652D BaseThreadInitThunk()+d
ANR9999D Thread<0>  00000000773EC521 RtlUserThreadStart()+21
ANR9999D_3325034490 GetDB2LevelStr(rdbdb.c:11460) Thread<0>: Rc 1040 from
tbSQLExecuteToStrings for SELECT SERVICE_LEVEL FROM SYSIBMADM.ENV_INST_INFO.
ANR9999D Thread<0> issued message 9999 from:
ANR9999D Thread<0>  000007FEEAD52C69 OutDiagToCons()+159
ANR9999D Thread<0>  000007FEEAD4C62A outDiagfExt()+11a
ANR9999D Thread<0>  000007FEEAB06A23 RdbGetRegValues()+893
ANR9999D Thread<0>  000007FEEAB0F2C7 RdbCrossCheckDb2Level()+97
ANR9999D Thread<0>  000007FEEAA78CA8 dbiInit()+1b8
ANR9999D Thread<0>  000007FEEA50D59D AdmServerMonitorThread()+73d
ANR9999D Thread<0>  000007FEEA50ED2B admStartServer()+cb
ANR9999D Thread<0>  000007FEEA4F3474 adsmMain()+e84
ANR9999D Thread<0>  000000013F0F111B main()+9b dsmserv.c:241
ANR9999D Thread<0>  000000013F0F28DA __tmainCRTStartup()+11a crtexe.c:555
ANR9999D Thread<0>  00000000771B652D BaseThreadInitThunk()+d
ANR9999D Thread<0>  00000000773EC521 RtlUserThreadStart()+21
ANR9999D_2279234782 RdbCrossCheckDb2Level(rdbdb.c:5721) Thread<0>: Failed
(rc:1040 ) to retrieve the level of the IBM DB2 Database that is installed on
the system. Examine previous messages for problem determination information.
ANR9999D Thread<0> issued message 9999 from:
ANR9999D Thread<0>  000007FEEAD52C69 OutDiagToCons()+159
ANR9999D Thread<0>  000007FEEAD4C62A outDiagfExt()+11a
ANR9999D Thread<0>  000007FEEAB0F417 RdbCrossCheckDb2Level()+1e7
ANR9999D Thread<0>  000007FEEAA78CA8 dbiInit()+1b8
ANR9999D Thread<0>  000007FEEA50D59D AdmServerMonitorThread()+73d
ANR9999D Thread<0>  000007FEEA50ED2B admStartServer()+cb
ANR9999D Thread<0>  000007FEEA4F3474 adsmMain()+e84
ANR9999D Thread<0>  000000013F0F111B main()+9b dsmserv.c:241
ANR9999D Thread<0>  000000013F0F28DA __tmainCRTStartup()+11a crtexe.c:555
ANR9999D Thread<0>  00000000771B652D BaseThreadInitThunk()+d
ANR9999D Thread<0>  00000000773EC521 RtlUserThreadStart()+21

Just an FYI,

I tried the below
Code:
[LIST]set db2instance=server1
 
 db2 connect to TSMDB1
 
 db2 grant dbadm with dataaccess with accessctrl on database to user db2user1
 
 db2 grant secadm on database to user db2user1
[/LIST]
But when it comes to
Code:
C:\Program Files\Tivoli\TSM\db2\BIN>db2 grant dbadm with dataaccess with accessc
trl on database to user db2user1
DB21034E  The command was processed as an SQL statement because it was not a
valid Command Line Processor command.  During SQL processing it returned:
SQL1024N  A database connection does not exist.  SQLSTATE=08003

I think I am struck here, any help is appreciated.

My PROD TSM is 6.3.0 and my test TSM is 6.3.4
 
PREDATAR Control23

On the DR server, do you have a user ID for the instance that has the same name as on the prod server?
Did you create the instance on the DR server using the above ID?
Are you logged in that that user ID?

DB2 keeps in the database who the owner is, so when you try to restore a database, it's important that it is using the right user ID.
 
PREDATAR Control23

Thankyou Guys!
I was successfully able to restore the DB on TSM Server V.6.3.3 even though my PROD TSM Version was 6.3.1

I was seeing the below error in db2diag.0.log file and I have to change the drive letter and create archmeth1 directory for this to work, and I added that change to dsmserv.opt file

Code:
Failed to archive log file S0012372.LOG to G:\archivelog\archmeth1\SERVER1\TSMDB1\NODE0000\C0000001\ from C:\tsmdb1\active_log\.

Is this a normal WIndows/TSM thing, or I went wrong somewhere in correctly defining the resources?

And Lastly,
How do I make the copypool tapes as tapepool tapes in my DR server, is the below step correct?
Code:
q vol stg=tapepool
upd vol <vol_name> acc=destroyed wherestg=tapepool
Follow this on all tapepool tapes, is there any easy way to destroy all tapes?

Then I checkin the copypool tapes, How do I do that? I have 100+ copypool tapes, can an AUDIT work?
Can you please provide the next step of actually adding the copypool tapes so that they are read as tapepool tapes.

Help is much appreciated.

Thanks in Advance.
 
PREDATAR Control23

For the failed to archive, that's not the actual error, but the result of another error, so you'll have to dig deeper in the db2diag.log to see why the archive failed. Possibly a permission issue, or a path issue.

As for the tapes, the copy tapes will always be copy tapes, however if the primary are not there and you mark them as destroyed (in DR only), then TSM will automatically mount the copy tapes as long as they are checked in.
 
PREDATAR Control23

Thankyou marclant!

You guys made my DR literally a piece of cake.

I really appreciate your help and time on this.

And many thanks again.
 
Top