# Hive-Elasticsearch connectivity, RESOLVED

**URL:** https://discuss.elastic.co/t/hive-elasticsearch-connectivity-resolved/139849
**Category:** Elasticsearch
**Created:** [July 12, 2018, 10:46pm UTC](https://discuss.elastic.co/t/hive-elasticsearch-connectivity-resolved/139849 "2018-07-12T22:46:32Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![hsk04](https://avatars.discourse-cdn.com/v4/letter/h/c57346/32.png) [@hsk04](https://discuss.elastic.co/u/hsk04)
#### Post date: [July 12, 2018, 10:46pm UTC](https://discuss.elastic.co/t/hive-elasticsearch-connectivity-resolved/139849/1 "2018-07-12T22:46:33Z")

</div>

Hello all,

I am trying to create a external table from hive. The table will be created in Elasticsearch, but it is giving me connection refused error.

Hive - Present in Cloudera Quickstart VM  
Elasticsearch and Kibana - Present in Ubuntu Server VM

The Command used:  
$ create external table abc(.....)  
stored by 'org.elasticsearch.hadoop.hive.EsStorageHandler'  
tblproperties ( 'es.resource'='abc', 'es.index.auto.create'='true', 'es.nodes'='\<elastic\_IP\>', 'es.port'='9200');

Error:  
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. MetaException(message:Got exception: java.net.ConnectException Call From quickstart.cloudera/10.0.2.15 to quickstart.cloudera:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: [http://wiki.apache.org/hadoop/ConnectionRefused](http://wiki.apache.org/hadoop/ConnectionRefused))

Please provide any leads on how to overcome this problem.  
Thanks in advance.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [August 9, 2018, 10:46pm UTC](https://discuss.elastic.co/t/hive-elasticsearch-connectivity-resolved/139849/2 "2018-08-09T22:46:36Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
