# Spark-shell sc.esRDD fails with error: unrecognized parameter: \[\_local\]

**URL:** <https://discuss.elastic.co/t/spark-shell-sc-esrdd-fails-with-error-unrecognized-parameter--local/68351>\
**Category:** Elasticsearch\
**Tags:** es-hadoop\
**Created:** [December 7, 2016, 7:25pm UTC](https://discuss.elastic.co/t/spark-shell-sc-esrdd-fails-with-error-unrecognized-parameter--local/68351 "2016-12-07T19:25:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Apratim\_Sharma](https://avatars.discourse-cdn.com/v4/letter/a/2bfe46/32.png) [@Apratim\_Sharma](https://discuss.elastic.co/u/Apratim_Sharma)\
**Post date:** [December 7, 2016, 7:25pm UTC](https://discuss.elastic.co/t/spark-shell-sc-esrdd-fails-with-error-unrecognized-parameter--local/68351/1 "2016-12-07T19:25:52Z")

</div>

I am using elasticsearch-spark-13\_2.10-5.0.0-beta1.jar for spark 1.6 and elasticsearch version 5.0.2

I am trying the very basic code:

val lpiRDD = sc.esRDD("sdp/lpi")  
lpiRDD.count

And getting following error

Caused by: org.elasticsearch.hadoop.rest.EsHadoopInvalidRequest: request [/sdp/lpi/\_search] contains unrecognized parameter: [\_local]  
{"query":{"match\_all":{}}}  
at org.elasticsearch.hadoop.rest.RestClient.checkResponse(RestClient.java:488)  
at org.elasticsearch.hadoop.rest.RestClient.execute(RestClient.java:446)  
at org.elasticsearch.hadoop.rest.RestClient.execute(RestClient.java:436)  
at org.elasticsearch.hadoop.rest.RestRepository.scroll(RestRepository.java:363)  
at org.elasticsearch.hadoop.rest.ScrollQuery.hasNext(ScrollQuery.java:92)

Please help.

Thanks a lot  
Apratim

---

<div class="post-metadata">

**Author:** ![Apratim\_Sharma](https://avatars.discourse-cdn.com/v4/letter/a/2bfe46/32.png) [@Apratim\_Sharma](https://discuss.elastic.co/u/Apratim_Sharma)\
**Post date:** [December 7, 2016, 9:58pm UTC](https://discuss.elastic.co/t/spark-shell-sc-esrdd-fails-with-error-unrecognized-parameter--local/68351/2 "2016-12-07T21:58:14Z")

</div>

It was jar compatibility issue. Unfortunately it's really hard to find correct version of jar for elastic-spark.  
I found jar for my versions spark 1.6 scala 2.10 and es 5.0.2 at [https://mvnrepository.com/artifact/org.elasticsearch/elasticsearch-spark-13\_2.10/5.0.2](https://mvnrepository.com/artifact/org.elasticsearch/elasticsearch-spark-13_2.10/5.0.2)

After that it worked just fine.

Thanks

---

<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:** [January 4, 2017, 9:58pm UTC](https://discuss.elastic.co/t/spark-shell-sc-esrdd-fails-with-error-unrecognized-parameter--local/68351/3 "2017-01-04T21:58:38Z")

</div>

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