DB2 initialize environment variable

seb

ADSM.ORG Member
Joined
Jul 28, 2008
Messages
16
Reaction score
0
Points
0
Location
France - Massy(91)
PREDATAR Control23

Hello,

I would like to backup a DB2 database with TSM. This feature is integrated into Control Center GUI.
I follow the instructions supplied by IBM papers and on first step it goes on error.
I installed Tsm client and configure dsm.opt :
Code:
NODENAME        SAMETIMEGW
PASSWORDACCESS        Generate
TCPSERVERADDRESS    xxx.xxx.xxx.xxx
TCPPort              1500
COMMMethod          TCPIP
HTTPPort         1581
WEBPorts              1580 1582
COMPression         NO
SCHEDMode        PROMPTED
RetryPeriod        10
MaxCmdRetries        3
Errorlogretention    21 D
DATEFORMAT        2
When i launch Client GUI it works well, but when i want to configure db2 to use Tsm server for backup (change circular logging to archive logging) I have a password error.

So I checked my environment variable and it appears good. DSMI_LOG, DSMI_DIR, and DSMI_CONFIG are set into "system variables" and for the db2 user into "user variables".

I run the dsmapipw.exe and i have this error :
*** Environment setup failed: (610) Unknown rc.
I'm asking to myself if DB2 service must have the "Local system" user in launcher instead a db2 user created by the administrator for the support of Tsm backup in Db2 ??

(Windows 2003) TSM Server : 5.5.1.0
(Windows 2003) TSM Client (Db2 server) : 5.5.0.0
(Windows 2003) DB2 : 9.1

Thanks,
Seb
 
PREDATAR Control23

I check your tow links and i have the error again.

I changed my dsm_dir with "c:\Program files\Tivoli\TSM\api\bin" because into ibm document for db2 backup on windows (for win2000) they tell about a variable set to "...TSM\api" and not \bin after. I restarted db2 service and ERRORR !

Even if your links is for LINUX/UNIX server, i did all steps but not resolving my issue.

The step 2 tell about a db2profile file. The only db2profile file existing on my system is db2profile.bat and it contain "SET DB2INSTANCE=DB2". If i set my env variable on windows i think it is not necessary to add env variable on this file. When i check my env var with the "set" command i see all DSMI_* var !

Thanks for help Rudy
 
PREDATAR Control23

I run the dsmapipw.exe and i have this error :
I'm asking to myself if DB2 service must have the "Local system" user in launcher instead a db2 user created by the administrator for the support of Tsm backup in Db2 ??

(Windows 2003) TSM Server : 5.5.1.0
(Windows 2003) TSM Client (Db2 server) : 5.5.0.0
(Windows 2003) DB2 : 9.1

Thanks,
Seb

When you check all your env variables, are you logged with the db2 user? The one that starts the DB2 service.

Rudy
 
PREDATAR Control23

Hello,

I checked variables from db2 user and administrator user. All variables are set correctly.

I check the dsmapipw.exe software with microsoft sysinternalsuite utilities (regmon.exe and procmon.exe) in order to see all activities from this program and all call which it use. With procmon.exe I see that dsmapipw.exe want to access to the dscenu.txt in sqlib\bin directory.

When i copy this file on sqllib\bin directory the program update the password normally. Then when i configure db2 logging and test backup with TSM i have the error again.

I think it's really a environment variables setting

Thanks
 
PREDATAR Control23

it is probably because someone from IBM suddenly decide to move api dir from c:\program files\tivoli\tsm\ to c:\program files\common files\tivoli\tsm\ and to tell it to no one.
If you have another api dir on old place, after c:\program files\tivoli\tsm\, it is because you have installed api sdk.
So, you have to point your DSMI_DIR variable to c:\program files\common files\tivoli\tsm\api.
 
PREDATAR Control23

I ,

No, nobody changed the current API path because it is the first tivoli installation... I know it's an issue around the variables declaration.

I will try to configure DSM_* variables for see (more DSMI var).

Thanks mita201
 
PREDATAR Control23

Seb,

Sorry for my bad english, but you understood me wrongly.
You were reffering to an old document that instruct you to set operating system variable DSMI_DIR to c:\Program files\Tivoli\TSM\api, which was correct with TSM 5.4 and earlier.
Now, starting with TSM 5.5, api that you should point to with DSMI_DIR OS environment variable is at c:\program files\common files\tivoli\tsm\, and I can't find it in docs, I just find it after many hours experiencing same problem as you did.
 
PREDATAR Control23

Hello,

I know it's been a long time but I ran into this problem today and I wanted to share the related IBM link.

http://www-01.ibm.com/support/docview.wss?uid=swg21420849

Basically, you have to make sure that there is a dscenu.txt file in the directory pointed by DSMI_DIR. You can copy it from C:\Program Files\Tivoli\TSM\baclient.
 
PREDATAR Control23

To add to this, I was working through a similar issue on a new 6.1x Linux test server. I had spent hours tracking down info on properly configuring the server and client. Setting variables, configuring instance etc.. Mostly simply attempting to verify the configuration vs resorting to a complete reinstall.

My TSM server was running fine no issues, just couldn't perform the DB backup. So I knew it was client/config related. Ultimately here is what lead me to this conclusion. From some IBM articles as well as some forum and web posts i used: "db2adutl query " This allowed me to clearly separate the issue from a TSM/DB2 server issue to environment/client config issue.


End result the TSM client didn't get installed correctly and was causing similar issues.

TSM Client Removal
rpm -ev TIVsm-BA-6.1.3-4
rpm -ev TIVsm-API-6.1.3-4
rpm -ev TIVsm-API64-6.1.3-4

TSM Client Install
rpm -iv TIVsm-API.i386.rpm
rpm -iv TIVsm-API64.i386.rpm
rpm -iv TIVsm-BA.i386.rpm
rpm -qa|grep TIV

Maybe this will help someone.
 
Top