Connectivity of R and Elasticsearch

Hi I have a problems making R to work with Elasticsearch via ssh tunnelling on CentOS 7. SSH tunnel is already setup via putty.
I have installed Rstudio and R (server). I connect to Elasticsearch:

connect(es_host = "<host_address>",es_port = "9200",es_path = "")

When I try to use ping(), I get following error:

ping()
Error: lexical error: invalid char in json text.
<!DOCTYPE HTML PUBLIC "-//W3C//
(right here) ------^

Is it problem with connection, elasticsearch, incompatibility...?

  1. Proxy is set up in Renviron.site file as:

http_proxy = <http_address>:
http_proxy_user=user:pass

https_proxy = <http_address>:
https_proxy_user=user:pass

  1. R version: 3.4.1 Rstudio version: 1.0.44

  2. Elasticsearch version: 2.3.3

I will appreciate any advice. Thanks,

Leon

It looks like a proxy issue, can you try it without the proxy?

Thanks for reply Mark,
When I comment out proxy lines in Renviron.site,
I get following back:
"Error in curl::curl_fetch_memory(url, handle = handle) :
Could not resolve host: ; Name or service not known"
Kind Regards,
Leon

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