Unix Technical Forum

Perl DBD::DB2 connect error

This is a discussion on Perl DBD::DB2 connect error within the DB2 forums, part of the Database Server Software category; --> I'm attempting to connect to a DB2 database using DBD: B2 running on a Linux device. I'm getting the ...


Go Back   Unix Technical Forum > Database Server Software > DB2

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-27-2008, 02:03 PM
roxrox_1959@yahoo.com
 
Posts: n/a
Default Perl DBD::DB2 connect error

I'm attempting to connect to a DB2 database using DBD:B2 running on
a Linux device. I'm getting the following error:

** connect: Unable to get database handle: DBI
connect('p88flaq','ip88flaq',...) failed: [IBM][CLI Driver] SQL1042C
An unexpected system error occurred. SQLSTATE=58004
at /usr/lib/perl5/site_perl/5.8.5/Oasis2/DBConn.pm line 2155

I've installed the DB2 client for the user in question:

../db2icrt -a SERVER_ENCRYPT -s client -w32 orbit

The user CAN connect using the db2 command line interface.

I know (think!) that I need to install the 'Developers Toolkit' but I
can't find any reference as to how to install this.

I have another account on the same device that CAN connect usiing
DBD:B2 but I can't remember what I did to get this user working.
The DB2 DBA that we had up and quit and didn't leave behind many
notes :-(

Any help would be appreciated!

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-27-2008, 02:04 PM
dotyet
 
Posts: n/a
Default Re: Perl DBD::DB2 connect error

on the two accounts, type the following commands and see if they are
pointing to two different installations of db2:

db2level

also check if the perl and db2 dbi module are installed on the system
as a whole or is custom for the user which is capable of running it.

regards,
dotyet

On Aug 9, 3:54 pm, roxrox_1...@yahoo.com wrote:
> I'm attempting to connect to a DB2 database using DBD:B2 running on
> a Linux device. I'm getting the following error:
>
> ** connect: Unable to get database handle: DBI
> connect('p88flaq','ip88flaq',...) failed: [IBM][CLI Driver] SQL1042C
> An unexpected system error occurred. SQLSTATE=58004
> at /usr/lib/perl5/site_perl/5.8.5/Oasis2/DBConn.pm line 2155
>
> I've installed the DB2 client for the user in question:
>
> ./db2icrt -a SERVER_ENCRYPT -s client -w32 orbit
>
> The user CAN connect using the db2 command line interface.
>
> I know (think!) that I need to install the 'Developers Toolkit' but I
> can't find any reference as to how to install this.
>
> I have another account on the same device that CAN connect usiing
> DBD:B2 but I can't remember what I did to get this user working.
> The DB2 DBA that we had up and quit and didn't leave behind many
> notes :-(
>
> Any help would be appreciated!



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-27-2008, 02:04 PM
roxrox_1959@yahoo.com
 
Posts: n/a
Default Re: Perl DBD::DB2 connect error

On Aug 9, 5:12 pm, dotyet <dot...@yahoo.com> wrote:
> on the two accounts, type the following commands and see if they are
> pointing to two different installations of db2:
>
> db2level
>
> also check if the perl and db2 dbi module are installed on the system
> as a whole or is custom for the user which is capable of running it.
>
> regards,
> dotyet
>
> On Aug 9, 3:54 pm, roxrox_1...@yahoo.com wrote:
>
> > I'm attempting to connect to a DB2 database using DBD:B2 running on
> > a Linux device. I'm getting the following error:

>
> > ** connect: Unable to get database handle: DBI
> > connect('p88flaq','ip88flaq',...) failed: [IBM][CLI Driver] SQL1042C
> > An unexpected system error occurred. SQLSTATE=58004
> > at /usr/lib/perl5/site_perl/5.8.5/Oasis2/DBConn.pm line 2155

>
> > I've installed the DB2 client for the user in question:

>
> > ./db2icrt -a SERVER_ENCRYPT -s client -w32 orbit

>
> > The user CAN connect using the db2 command line interface.

>
> > I know (think!) that I need to install the 'Developers Toolkit' but I
> > can't find any reference as to how to install this.

>
> > I have another account on the same device that CAN connect usiing
> > DBD:B2 but I can't remember what I did to get this user working.
> > The DB2 DBA that we had up and quit and didn't leave behind many
> > notes :-(

>
> > Any help would be appreciated!

Thanks,

The perl is installed so that everyone has access.

The db2level shows that the user that 'works' has 64 bit vs 32 bit for
the user that doesn't 'work'. I'll see if I can fix that.



[root@mdsxocd1 ~]# su - orbit
[orbit@mdsxocd1 ~]$ db2level
DB21085I Instance "orbit" uses "64" bits and DB2 code release
"SQL08026" with
level identifier "03070106".
Informational tokens are "DB2 v8.1.3.120", "s060801", "MI00167", and
FixPak
"13".
Product is installed at "/opt/IBM/db2/V8.1".

[orbit@mdsxocd1 ~]$
[root@mdsxocd1 ~]# su - appit
[appit@mdsxocd1 ~]$ db2level
DB21085I Instance "appit" uses "32" bits and DB2 code release
"SQL08026" with
level identifier "03070106".
Informational tokens are "DB2 v8.1.3.120", "s060801", "MI00167", and
FixPak
"13".
Product is installed at "/opt/IBM/db2/V8.1".

[appit@mdsxocd1 ~]$



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-27-2008, 02:04 PM
roxrox_1959@yahoo.com
 
Posts: n/a
Default Re: Perl DBD::DB2 connect error

On Aug 10, 9:14 am, roxrox_1...@yahoo.com wrote:
> On Aug 9, 5:12 pm, dotyet <dot...@yahoo.com> wrote:
>
> > on the two accounts, type the following commands and see if they are
> > pointing to two different installations of db2:

>
> > db2level

>
> > also check if the perl and db2 dbi module are installed on the system
> > as a whole or is custom for the user which is capable of running it.

>
> > regards,
> > dotyet

>
> > On Aug 9, 3:54 pm, roxrox_1...@yahoo.com wrote:

>
> > > I'm attempting to connect to a DB2 database using DBD:B2 running on
> > > a Linux device. I'm getting the following error:

>
> > > ** connect: Unable to get database handle: DBI
> > > connect('p88flaq','ip88flaq',...) failed: [IBM][CLI Driver] SQL1042C
> > > An unexpected system error occurred. SQLSTATE=58004
> > > at /usr/lib/perl5/site_perl/5.8.5/Oasis2/DBConn.pm line 2155

>
> > > I've installed the DB2 client for the user in question:

>
> > > ./db2icrt -a SERVER_ENCRYPT -s client -w32 orbit

>
> > > The user CAN connect using the db2 command line interface.

>
> > > I know (think!) that I need to install the 'Developers Toolkit' but I
> > > can't find any reference as to how to install this.

>
> > > I have another account on the same device that CAN connect usiing
> > > DBD:B2 but I can't remember what I did to get this user working.
> > > The DB2 DBA that we had up and quit and didn't leave behind many
> > > notes :-(

>
> > > Any help would be appreciated!

>
> Thanks,
>
> The perl is installed so that everyone has access.
>
> The db2level shows that the user that 'works' has 64 bit vs 32 bit for
> the user that doesn't 'work'. I'll see if I can fix that.
>
> [root@mdsxocd1 ~]# su - orbit
> [orbit@mdsxocd1 ~]$ db2level
> DB21085I Instance "orbit" uses "64" bits and DB2 code release
> "SQL08026" with
> level identifier "03070106".
> Informational tokens are "DB2 v8.1.3.120", "s060801", "MI00167", and
> FixPak
> "13".
> Product is installed at "/opt/IBM/db2/V8.1".
>
> [orbit@mdsxocd1 ~]$
> [root@mdsxocd1 ~]# su - appit
> [appit@mdsxocd1 ~]$ db2level
> DB21085I Instance "appit" uses "32" bits and DB2 code release
> "SQL08026" with
> level identifier "03070106".
> Informational tokens are "DB2 v8.1.3.120", "s060801", "MI00167", and
> FixPak
> "13".
> Product is installed at "/opt/IBM/db2/V8.1".
>
> [appit@mdsxocd1 ~]$


BINGO!

I reinstalled the client with the following command:

../opt/IBM/db2/V8.1/instance/db2icrt -a SERVER_ENCRYPT -s client -w 64
appit

After I registered the database I could connect.

Many thanks!!!

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 07:41 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com