Topic
IC4NOTICE: developerWorks Community will be offline May 29-30, 2015 while we upgrade to the latest version of IBM Connections. For more information, read our upgrade FAQ.
1 reply Latest Post - ‏2008-06-03T20:56:50Z by SystemAdmin
SystemAdmin
SystemAdmin
262 Posts
ACCEPTED ANSWER

Pinned topic Error 8006 CWB0999 when attempting to connect via an SSH tunnel

‏2008-05-28T23:57:35Z |
We are receiving the following error message when we attempt to connect from a Linux server to an AS/400, by using the iSeries Access for Linux software. What is the solution to this problem?

  1. isql -v my400db
28000unixODBCIBMiSeries Access ODBC DriverCommunication link failure. comm rc=8006 - CWB0999 - Unexpected error: unexpected return code 8006, Password length = 0, Prompt Mode = Never, System IP Address = 127.0.0.1
ISQLERROR: Could not SQLConnect

We have a Linux computer (i.e. 1.1.1.1), a firewall computer (i.e. 2.2.2.2), and an AS/400 computer (i.e. 3.3.3.3) that is behind the firewall computer. We are attempting to make the connection through an SSH tunnel, from the Linux client computer, through the firewall computer, and finally to the AS/400 computer, as pictured below.

Linux <--> Firewall <--> AS/400
(1.1.1.1) (2.2.2.2) (3.3.3.3)

We are using the following command on the Linux computer to create the SSH tunnel. SSH on the firewall is set to port 1815. We assume that traffic for the iSeries Access for Linux goes over port 8471 (is this correct?), so we have included that. 3.3.3.3 is the AS/400 computer. We assume that the traffic should be directed to port 446 on the AS/400 (is this correct?). 2.2.2.2 is the firewall computer.

/usr/bin/ssh -p 1815 -N -L8471:3.3.3.3:446 user@2.2.2.2

The odbc.ini content appears below.

my400db
Description = iSeries Access ODBC Driver DSN for iSeries
Driver = iSeries Access ODBC Driver
System = localhost
UserID = example
Password = example
Naming = 0
DefaultLibraries = QGPL
Database =
ConnectionType = 0
CommitMode = 2
ExtendedDynamic = 0
DefaultPkgLibrary = QGPL
DefaultPackage = A/DEFAULT(IBM),2,0,1,0,512
AllowDataCompression = 1
LibraryView = 0
AllowUnsupportedChar = 0
ForceTranslation = 0
Trace = 0

We currently have an older Linux computer that successfully connects to the same AS/400 using an SSH tunnel, but it is using old DB2 Version 8 Client Connect software. That old Linux computer is successfully using the following command to create the SSH tunnel.

/usr/bin/ssh -p 1815 -N -L5001:3.3.3.3:446 user@2.2.2.2

Thanks for any help.

Message was edited by: chrisa2
Updated on 2008-06-03T20:56:50Z at 2008-06-03T20:56:50Z by SystemAdmin
  • SystemAdmin
    SystemAdmin
    262 Posts
    ACCEPTED ANSWER

    Re: Error 8006 CWB0999 when attempting to connect via an SSH tunnel

    ‏2008-06-03T20:56:50Z  in response to SystemAdmin
    The solution to this problem was to connect to port 8471 on the AS/400 instead of port 446. Connecting to the DDM port (i.e. 446) did not work for some reason. The SSH tunneling has been updated accordingly, like below.

    /usr/bin/ssh -p 1815 -N -L8471:3.3.3.3:8471 user@2.2.2.2