How to resolve error "Socket communication failure for Packet receive" while querying against Teradata from TIBCO Data Virtualization?

How to resolve error "Socket communication failure for Packet receive" while querying against Teradata from TIBCO Data Virtualization?

book

Article ID: KB0071503

calendar_today

Updated On:

Products Versions
TIBCO Data Virtualization All supported versions

Description

Query against Teradata from TIBCO Data Virtualization (TDV) fails with the following error (from cs_server_client.log file) :

Caused by: java.sql.SQLException: [Teradata JDBC Driver] [TeraJDBC 15.10.00.37] [Error 804] [SQLState 08S01] Socket communication failure for Packet receive Tue Dec 15 14:34:41 GMT 2020 socket orig=TDPROD.GB.TNTPOST.COM local=0.0.0.0/0.0.0.0:45166 remote=[machine_name]/[IP]:1025 keepalive=unavailable nodelay=unavailable receive=unavailable send=unavailable linger=unavailable traffic=unavailable concurrent=3 contimeout=10000 conwait=1000 connecttime=21 connecttotaltime=22 connectattempts=1 connectfailures=0 reconnectattempts=0 recoverable=false redrive=false failurecache={} cid=442bdf09 sess=52404361 java.io.IOException: Incomplete LAN message header: read 0 bytes  at com.teradata.jdbc.jdbc_4.io.TDNetworkIOIF.read(TDNetworkIOIF.java:748)
...
Caused by: java.io.IOException: Incomplete LAN message header: read 0 bytes
at com.teradata.jdbc.jdbc_4.io.TDNetworkIOIF.read(TDNetworkIOIF.java:748)
... 26 more

cs_server_events.log shows the request to be TERMINATED - 

----
80335777 | [NULL] | 4081890 | 7363987 | 117044 | j400syr | SQL | TERMINATED | SELECT C1."Con_Number" AS "CONNUMBER", C2."CON_CREATE_DT" AS "CONCREATEDATE", C1."Con_Create_Depot" AS "CONCREATEDEPOT", trim(C3."CPN_NM") AS "SENDERCOMPANYNAME", trim(C4."CPN_NM")..
----

Issue/Introduction

How to resolve error "Socket communication failure for Packet receive" while querying against Teradata from TIBCO Data Virtualization?

Environment

All supported Operating Systems

Resolution

This is caused by the Teradata JDBC driver incompatibility. To resolve this issue, use the latest & compatible Teradata JDBC driver in TDV.

Note: Make a backup of the existing jar files under [TDV_Server_dir]/conf/adapters/system/teradata_<version> to a location outside TDV Server directory

Steps to obtain and install the JDBC driver for Teradata :

1. Download the latest version of Teradata JDBC drivers, which are packaged in a zip or TAR archive.
For example, you can navigate to following Teradata download site to obtain the Teradata JDBC drivers: https://downloads.teradata.com/download/connectivity/jdbc-driver
2. Copy the following adapter JARs from the Teradata driver archive:

Teradata 13Teradata 14Teradata 15Teradata 16
tdgssconfig.jartdgssconfig.jartdgssconfig.jartdgssconfig.jar
terajdbc4.jarterajdbc4.jarterajdbc4.jarterajdbc4.jar

3. Depending of the adapter version being used in TDV, update the Teradata DB version JAR files in the TDV installation directory at: [TDV_Server_dir]/conf/adapters/system/teradata_<version>.
Example, If you are connecting to Teradata 14 and are using the Teradata 14 adapter in TDV, the jar files need to be updated under [TDV_Server_dir]/conf/adapters/system/teradata_14. 
4. Restart the TDV Server to initiate use of the new adapter JAR files.

Additional Information

Relevant articles from the web - 
https://community.teradata.com/t5/Connectivity/Error-quot-java-io-IOException-Bad-response-message-header-with/td-p/77492
http://developer.teradata.com/doc/connectivity/jdbc/reference/current/platformMatrix.html