If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > a problem using rsh to get db2 information on the remote server

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-03-04, 03:06
newhu114 newhu114 is offline
Registered User
 
Join Date: Jul 2004
Posts: 17
a problem using rsh to get db2 information on the remote server

I am developping a program to watch the remote DB2 Servers. I use the rsh command to access the DB2 servers. I use the "db2inst2" user to rsh to remote server's information.
When I use following command in the local ,
rsh dbsvr1 "db2 get instance"
it shows following errors:
SQL10007N Message "-1390" could not be retrieved. Reason code: "1".
However, I can use "rsh dbsvr1 df -k" correctly. I have search the reason,maybe the user's profiles in the local and remote server are different,but I can not reset the local user's profile as the same as remote server's.
Who can tell me how to do?
Reply With Quote
  #2 (permalink)  
Old 08-03-04, 21:22
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
Quote:
Originally Posted by newhu114
I am developping a program to watch the remote DB2 Servers. I use the rsh command to access the DB2 servers. I use the "db2inst2" user to rsh to remote server's information.
When I use following command in the local ,
rsh dbsvr1 "db2 get instance"
it shows following errors:
SQL10007N Message "-1390" could not be retrieved. Reason code: "1".
I suspect you will need to execute db2 profile before invoking CLP. Try this:
Code:
rsh dbsvr1 ". /home/dbsvr1/db2profile;db2 get instance"
I'm not sure about the profile script name - check if it's correct.
Reply With Quote
  #3 (permalink)  
Old 08-04-04, 04:33
newhu114 newhu114 is offline
Registered User
 
Join Date: Jul 2004
Posts: 17
you are right,it's done!
thanks!
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On