469,282 Members | 1,701 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,282 developers. It's quick & easy.

DB2 Federated connection problems

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
2 4870
"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
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.

Similar topics

1 post views Thread by ansonee | last post: by
reply views Thread by stevenkblack | last post: by
2 posts views Thread by vrbala | last post: by
1 post views Thread by terryintransit | last post: by
2 posts views Thread by mas5 | last post: by
9 posts views Thread by mitek | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.