Hive Jobs Fail - SocketTimeoutException: Read timed out

Problem

When executing a Hive, creating a Hive Connection or editing an existing Hive connection, a java.net.SocketTimeoutException is thrown. The initial content in the stacktrace is as follows:

WARN [2015-01-01 10:25:48.314] [239779852@qtp-69190395-5] (DataStore.java:189) - connection fails: Can't read table names: Can't read table names: java.net.SocketTimeoutException: Read timed out
java.lang.RuntimeException: Can't read table names: Can't read table names: java.net.SocketTimeoutException: Read timed out
        at datameer.das.plugin.hive.HiveDataStoreModel.testConnect(HiveDataStoreModel.java:72)
        at datameer.dap.sdk.entity.DataStore.validate(DataStore.java:186)
        at datameer.dap.conductor.webapp.commandObject.ConnectionCommand.validateConnection(ConnectionCommand.java:121)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.springmodules.validation.bean.rule.ValidationMethodValidationRule$MethodCondition.doCheck(ValidationMethodValidationRule.ja\
va:39)
        at org.springmodules.validation.util.condition.AbstractCondition.check(AbstractCondition.java:36)
        at org.springmodules.validation.bean.BeanValidator.validateAndShortCircuitRules(BeanValidator.java:429)
        at org.springmodules.validation.bean.BeanValidator.applyPropertiesValidationRules(BeanValidator.java:412)
        at org.springmodules.validation.bean.BeanValidator.applyBeanValidation(BeanValidator.java:349)
        at org.springmodules.validation.bean.BeanValidator.validateObjectGraphConstraints(BeanValidator.java:181)
        at org.springmodules.validation.bean.BeanValidator.validate(BeanValidator.java:99)
        at datameer.dap.conductor.webapp.controller.data.datastore.DataStoreW2DetailsController.submitConnectionDetails(DataStoreW2Details\
Controller.java:128)
        at datameer.dap.conductor.webapp.controller.data.datastore.DataStoreW2DetailsController$$FastClassByCGLIB$$d340b755.invoke(<genera\
ted>)

This issue is only observed in environments that are using MySQL to store the Hive Metastore information.

Cause

This issue is caused by a misconfiguration of a Hive connection. Specifically, the Hive connection is pointed directly to the Hive Server or Hive Server 2 port. The correct configuration requires pointing Datameer at the Hive Metastore port, 9083 by default.

Solution

To resolve this issue, ensure that the Datameer Hive Connection is pointed at the Hive Metastore port. This value is determined by the "hive.metastore.uris" parameter on the Hive Server.

The Hive Metastore port is available in the hive-site.xml configuration file of the Hive server. If unknown, please contact the Hive Administrator to confirm the active port for the Hive Metastore.