By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,756 Members | 1,745 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,756 IT Pros & Developers. It's quick & easy.

DB2 Federated connection problems

P: n/a
Here's the layout: AIX v5.2, DB2 v8 fp8 running in 64bit

I've got a Multi-partitioned db running on lpar4 and I want to
connect it to 2 instances running on lpar13. We'll deal with just
1 instance on lpar13 for now.

lpar4 -> db name dwdb
lpar13 -> db name IBMEDGE

On lpar13, I have a userid that has DBADMIN authority.
ID: userid PW: passwd
Our dba cataloged IBMEDGE on our lpar4 machine with no problems.

I can connect to it from lpar4 with the follwing command:
db2 connect to IBMEDGE user userid using passwd
Federated part:

(I got this out of the Configuring Federated Data Source manual, so I
did RTFM :) )

I created a DRDA wrapper with no problems.

-> create wrapper DRDA library 'libdb2drda.a'
I then created a server (ran successfully)

-> create server EDGESRC type DB2/UDB version 8 wrapper DRDA
authorization "userid" password "passwd"
options (DBNAME 'IBMEDGE', FOLD_ID 'L', FOLD_PW 'L');

I then created a user_mapping (ran successfully)
-> create user mapping for userid server EDGESRC
options (REMOTE_AUTHID 'userid', REMOTE_PASSWORD 'passwd');

When I try to test the connection or create a nickname, I get a
userid/passwd error (SQL1101N SQLSTATE=08004).

The userid/passwd combo work fine when I telnet or do a direct DB2 connect
to it.

The quotes and FOLD options should force it to lowercase.

Both instances have FEDERATED set to 'YES' in the dbm cfg.
It would probably be easier to do it in the control center, but IGS has
it blocked by an firewall.

I just can't figure out what why it doesn't like the supplied info.

--
Tim.

"Those who give up essential liberties for temporary safety deserve neither
liberty nor safety." - Benjamin Franklin
Nov 12 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
"Tim V." <va****@us.ibm.com> wrote in
news:Xn**********************************@207.115. 17.102:

I figured it out. Regardless of what you put in the
'create server' part, it doesn't get sent. When you try
to connect via Federated server, it's sending the OS ID
you are logged in as. So, if I'm logged in as 'db2inst1',
that's the ID/PWD combo that gets sent, even if I define the
server with a different UID. I had to create a 'user mapping'
that xlates 'db2inst1' -> 'userid'.

It's not clearly (at least to me) explained in the doc.

Tim.

Here's the layout: AIX v5.2, DB2 v8 fp8 running in 64bit

I've got a Multi-partitioned db running on lpar4 and I want to
connect it to 2 instances running on lpar13. We'll deal with just
1 instance on lpar13 for now.

lpar4 -> db name dwdb
lpar13 -> db name IBMEDGE

On lpar13, I have a userid that has DBADMIN authority.
ID: userid PW: passwd
Our dba cataloged IBMEDGE on our lpar4 machine with no problems.

I can connect to it from lpar4 with the follwing command:
db2 connect to IBMEDGE user userid using passwd
Federated part:

(I got this out of the Configuring Federated Data Source manual, so I
did RTFM :) )

I created a DRDA wrapper with no problems.

-> create wrapper DRDA library 'libdb2drda.a'
I then created a server (ran successfully)

-> create server EDGESRC type DB2/UDB version 8 wrapper DRDA
authorization "userid" password "passwd"
options (DBNAME 'IBMEDGE', FOLD_ID 'L', FOLD_PW 'L');

I then created a user_mapping (ran successfully)
-> create user mapping for userid server EDGESRC
options (REMOTE_AUTHID 'userid', REMOTE_PASSWORD 'passwd');

When I try to test the connection or create a nickname, I get a
userid/passwd error (SQL1101N SQLSTATE=08004).

The userid/passwd combo work fine when I telnet or do a direct DB2
connect to it.

The quotes and FOLD options should force it to lowercase.

Both instances have FEDERATED set to 'YES' in the dbm cfg.
It would probably be easier to do it in the control center, but IGS
has it blocked by an firewall.

I just can't figure out what why it doesn't like the supplied info.


--
Tim.

"Those who give up essential liberties for temporary safety deserve neither
liberty nor safety." - Benjamin Franklin
Nov 12 '05 #2

P: n/a
The userid and pw that you put in the create server
statement are NOT used for normal connections, they are used
for other "misc" stuff (misteriously pointed in:
http://publib.boulder.ibm.com/infoce...n/r0002170.htm

The one that is used is the one you
are currently connected as (if there is no user mapping) or
the user/pw defined in the user mapping.

Your user mapping is suspect. It indicates that you have
the same user "userid" on both instances. What you need is
create user mapping for local_user_id server
....(... 'remote_user_id', ...'remote pw')

Michael

On Thu, 29 Sep 2005, Tim V. wrote:
"Tim V." <va****@us.ibm.com> wrote in
news:Xn**********************************@207.115. 17.102:

I figured it out. Regardless of what you put in the
'create server' part, it doesn't get sent. When you try
to connect via Federated server, it's sending the OS ID
you are logged in as. So, if I'm logged in as 'db2inst1',
that's the ID/PWD combo that gets sent, even if I define the
server with a different UID. I had to create a 'user mapping'
that xlates 'db2inst1' -> 'userid'.

It's not clearly (at least to me) explained in the doc.

Tim.

Here's the layout: AIX v5.2, DB2 v8 fp8 running in 64bit

I've got a Multi-partitioned db running on lpar4 and I want to
connect it to 2 instances running on lpar13. We'll deal with just
1 instance on lpar13 for now.

lpar4 -> db name dwdb
lpar13 -> db name IBMEDGE

On lpar13, I have a userid that has DBADMIN authority.
ID: userid PW: passwd
Our dba cataloged IBMEDGE on our lpar4 machine with no problems.

I can connect to it from lpar4 with the follwing command:
db2 connect to IBMEDGE user userid using passwd
Federated part:

(I got this out of the Configuring Federated Data Source manual, so I
did RTFM :) )

I created a DRDA wrapper with no problems.

-> create wrapper DRDA library 'libdb2drda.a'
I then created a server (ran successfully)

-> create server EDGESRC type DB2/UDB version 8 wrapper DRDA
authorization "userid" password "passwd"
options (DBNAME 'IBMEDGE', FOLD_ID 'L', FOLD_PW 'L');

I then created a user_mapping (ran successfully)
-> create user mapping for userid server EDGESRC
options (REMOTE_AUTHID 'userid', REMOTE_PASSWORD 'passwd');

When I try to test the connection or create a nickname, I get a
userid/passwd error (SQL1101N SQLSTATE=08004).

The userid/passwd combo work fine when I telnet or do a direct DB2
connect to it.

The quotes and FOLD options should force it to lowercase.

Both instances have FEDERATED set to 'YES' in the dbm cfg.
It would probably be easier to do it in the control center, but IGS
has it blocked by an firewall.

I just can't figure out what why it doesn't like the supplied info.


--
Tim.

"Those who give up essential liberties for temporary safety deserve neither
liberty nor safety." - Benjamin Franklin


---
Michael Ortega-Binderberger mi**@acm.org, mi**@ics.uci.edu
Department of Computer Science mi**@computer.org, m.******@ieee.org
U. of Illinois, Urbana-Champaign http://www-db.ics.uci.edu/~miki
949-824-7231 fax: 949-824-4056
UC Irvine Database Research Group 444 Computer Science,
On loan to the University of U. of California at Irvine,
California, Irvine (Researcher) Irvine, CA, 92697-3425

Nov 12 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.