Configuring TSM environment to back up DB2 to external server

capacityplanner

Active Newcomer
Joined
Sep 15, 2015
Messages
6
Reaction score
0
Points
0
Hi,
we're trying to get TSM configured on a RHEL DB2 server so we can back up the DB2 instance to an external TSM server. As far as I can tell, we've got the correct files in the right places, and the correct entries in those files. However, when we run the dsmapipw command, it fails with the return code (409) Invalid server name from client. The only thing that we might not have is that some documentation sources mention a tsmdbmgr.opt file that's supposed to go in the /home/(tsminst1)/(tsminst1) directory.

Can someone help me get this sorted?
 
Hi,
Not sure about your scenario:
1. You have TSM server installed, and you want to backup its own DB2 (TSM DB)
2. You have TSM infrastructure in place, and you have another DB2 server that you will like to backup to TSM?
Which one is true?

m.
 
Hi,
Not sure about your scenario:
1. You have TSM server installed, and you want to backup its own DB2 (TSM DB)
2. You have TSM infrastructure in place, and you have another DB2 server that you will like to backup to TSM?
Which one is true?

m.

We have a TSM infrastructure in place, and are adding a DB2 server that we want to back up using TSM.
 
Well, then there is no /home/(tsminst1)/(tsminst1) on a client I suppose....
So, you need to do on client (new DB2 server)
1. Install TSM BA client, that will bring TSM API with it
2. create files in api directory (I think on Linux it will go to /opt/tivoli/tsm/client/api/bin or bin64), dsm.opt and dsm.sys, readable by DB2 instance owner
Your dsm.sys must contain at least:
SErvername server_as_defined_in_dsm.opt

TCPServeraddress Name_or_IP_of_TSM_Server
nodename Name_As_Defined_on_TSM_Server



3. put three variables into DB2 owner environment (write it into .profile or sqllib/db2profile), something like:
export DSMI_CONFIG=/opt/tivoli/tsm/client/api/bin64/dsm.opt
export DSMI_LOG=/home/db2inst3
export DSMI_DIR=/opt/tivoli/tsm/client/api/bin64

Note: Your actual values will differ
restart db2 (db2stop, db2start) to pick up new env variables
try with dsmapipw.

On server (TSM Server) you need at least to register node for your new DB2 server

HTH,

m.
 
Well, then there is no /home/(tsminst1)/(tsminst1) on a client I suppose....
So, you need to do on client (new DB2 server)
1. Install TSM BA client, that will bring TSM API with it
2. create files in api directory (I think on Linux it will go to /opt/tivoli/tsm/client/api/bin or bin64), dsm.opt and dsm.sys, readable by DB2 instance owner
Your dsm.sys must contain at least:
SErvername server_as_defined_in_dsm.opt

TCPServeraddress Name_or_IP_of_TSM_Server
nodename Name_As_Defined_on_TSM_Server



3. put three variables into DB2 owner environment (write it into .profile or sqllib/db2profile), something like:
export DSMI_CONFIG=/opt/tivoli/tsm/client/api/bin64/dsm.opt
export DSMI_LOG=/home/db2inst3
export DSMI_DIR=/opt/tivoli/tsm/client/api/bin64

Note: Your actual values will differ
restart db2 (db2stop, db2start) to pick up new env variables
try with dsmapipw.

On server (TSM Server) you need at least to register node for your new DB2 server

HTH,

m.

All of those have been done. As noted in the OP, as far as I can tell, everything is where it's supposed to be, with the correct information entered. However, running dsmapipw results in error (409) when run.
 
There is probably error in your dsm.opt or dsm.sys - servername does not match - it should be the same.
 
It's gotta be a type-o in either the dsm.sys or dsm.opt for the servername option.
 
There is probably error in your dsm.opt or dsm.sys - servername does not match - it should be the same.

That's the problem. We've checked the dsm_db2.opt and the dsm.sys, and confirmed that the server name where we configured the db2 node is correct, no typos. There are two dsm.sys files: one in the /opt/Tivoli/tsm/client/api/bin64 directory and one in the .../client/ba/bin directory. The one in /ba/bin points to the server where we're doing regular operating system backups, and the /api/bin64 one points to the server that will hold the db2 backups. Is it possible that somehow the db2 environment is using the wrong .sys file i.e. the one in /ba/bin?
 
Sure it's possible, that's why I'm suggesting to strace and figure out what it's reading :D
 
dirtiest possible solution is - delete dsm.sys from api, write all stanzas into dsm.sys in ba, soft link it to api directory (make it readable by db owner)
 
Well, I re-ran the command, and this time it worked. The only change was that the DBA made a copy of the userprofile file in the directory where the db2 instance lives, named userfprofile. I'm still reading through the strace results to see if it tells me anything useful.
 
this might help...


edit /database/db2inst1/sqllib/userprofile


add the lines below in user profile


#############################################################################

#

[HASHTAG]#TSM[/HASHTAG]

#

export DSMI_CONFIG=/usr/tivoli/tsm/client/api/bin64/dsm.opt

export DSMI_LOG=/database/db2inst1/DSMI_LOG

export DSMI_DIR=/usr/tivoli/tsm/client/api/bin64

#############################################################################


db2stop

exit

login

db2start
 
Back
Top