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 > I can not connect to db2 database on windows 2003

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 03-30-08, 23:09
xiebotao xiebotao is offline
Registered User
 
Join Date: Mar 2008
Posts: 4
Red face I can not connect to db2 database on windows 2003

All

I installed the db2 8.1 & FP11 on windows 2003 professional server. But I get the following error when connect the database on server.
"SQL30081N A communication error has been detected. Communication protocol being used: "TCP/IP". Communication API being used: "SOCKETS". Location where the error was detected: "10.1.2.8". Communication function detecting the error: "connect". Protocol specific error code(s): "10061", "*", "*". SQLSTATE=08001"


the database can be connected on server locally.
db2 server's configuration as follow:

DB2SET DB2COMM=TCPIP
DBM cfgVCENAME=50000
run OS command "netstat -a" .There isn't TCPIP port 50000 in listening state on server.
and there isn't restriction on connection.

I can discover the database on server using configuration assistant.

Why?? .

Last edited by xiebotao; 03-30-08 at 23:14.
Reply With Quote
  #2 (permalink)  
Old 03-31-08, 02:41
guyprzytula guyprzytula is offline
Registered User
 
Join Date: Jun 2006
Posts: 471
I presume you have done db2stop/start after the modification of svcename...
is db2start giving any error - check diaglog
__________________
Best Regards, Guy Przytula
DB2 UDB LUW certified V6/7/8
Reply With Quote
  #3 (permalink)  
Old 03-31-08, 02:58
xiebotao xiebotao is offline
Registered User
 
Join Date: Mar 2008
Posts: 4
i can't connect to db2 server

Hi guyprzytula
the DB2stop & DB2start has isssued,and the db2 start sucessly,There is no any error info in db2diag.log when i connect to the db2 database.

issue os command "netstat -a" .There isn no TCPIP port 50000 in listening state on server.

thanks
Reply With Quote
  #4 (permalink)  
Old 03-31-08, 04:16
stolze stolze is offline
Registered User
 
Join Date: Jan 2007
Location: Jena, Germany
Posts: 2,662
A local connection does not go over TCP/IP but rather uses IPC (inter-process communication) to establish the connection. But you can and should try to define a loopback TCP/lP connection and connect that way. If this works, you have at least the correct network setup at DB2 side.

By looking at the explanation for SQL30081, I found this (in DB2 V9.5):
Quote:
  • If <protocol> = TCP/IP, <function> = connect, <rc1> =
    ECONNREFUSED/WSAECONNREFUSED, AIX (79), Windows (10061), linux (111),
    SUN (146), HP (239), the attempt to connect was rejected. Possible
    causes:
    • The remote database server has not been cataloged correctly at the
      client. In a client-gateway-server scenario, ensure the host
      entries are cataloged correctly on the gateway. See the Quick
      Beginnings guide for assistance.
    • The database manager configuration file at the server has not been
      configured properly with the proper communication parameters.
      Check that svcename has been configured properly with the TCP/IP
      service name or port number and that the port number is unique. If
      database manager configuration parameters have been updated at the
      server, the database manager must be stopped and re-started for
      the changes to take effect. There might be a mismatch between the
      TCP/IP service name or port number specified on the server and on
      the client. Ensure the service name maps to the correct port
      number by checking the services file. You can check this by
      reading the services file or checking the output of "netstat -a".
    • A firewall at the remote database server has prevented the
      connection from being established. Verify that the firewall is
      properly configured to accept connection requests from the client.
    • The DB2COMM environment variable at the server does not specify
      the communication protocol used by the client. Check that TCPIP
      has been specified. Issue db2set to see what has already been set.
      Issue db2set DB2COMM = TCPIP to set the value.
    • The database manager at the server has not been started, or has
      not been started successfully, or has gone down. The server should
      have returned SQL1063, and not SQL5043. If you set the database
      manager configuration parameter, diaglevel, to 4 using, db2 update
      dbm cfg using diaglevel 4, prior to issuing db2start, the
      administration notification log will provide detailed information
      on which protocols were started successfully. Check the
      administration notification log.
    • The server might be too busy to handle the volume of incoming
      connections at this time.
    • Network failure, contact your network administrator. You can try a
      test using the protocol tester, pctt, to verify this is not a DB2
      problem.
My best guess is that you didn't cataleg the TCP/IP node and/or the database correctly at your DB2 client.
__________________
Knut Stolze
IBM DB2 Analytics Accelerator
IBM Germany Research & Development
Reply With Quote
  #5 (permalink)  
Old 03-31-08, 04:44
xiebotao xiebotao is offline
Registered User
 
Join Date: Mar 2008
Posts: 4
I catalog the database using configuration assistant with search the network option,and i can find the Server' DB2 instance and database.
The catalog should be no problem.

I try catalog loopback TCP/lP connection on server.the same error occur also.
There is no port filter or restriction in TCPIP connection.
when issue "netstat -an" ,There is no TCPIP port(50000) in listening state.

I think the tcpip port(50000) is not active? but i dont known how to active the port
?
Reply With Quote
  #6 (permalink)  
Old 03-31-08, 05:25
stolze stolze is offline
Registered User
 
Join Date: Jan 2007
Location: Jena, Germany
Posts: 2,662
What exactly do you see (which messages) as result of "db2start"? Please post the output of "db2set". Also, check the "db2diag" output that is written during a "db2start".

Which version/edition of DB2 have you installed? If it is just the "personal edition", I believe you are just out of luck since this edition does not support remote connectivity - because it is, well, "personal".
__________________
Knut Stolze
IBM DB2 Analytics Accelerator
IBM Germany Research & Development
Reply With Quote
  #7 (permalink)  
Old 03-31-08, 22:56
xiebotao xiebotao is offline
Registered User
 
Join Date: Mar 2008
Posts: 4
Dear stolze

I have resolved the problem by download the db2ESE v8 FP16.

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