Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pio train error #19

Open
xiongjiewu opened this issue Sep 1, 2016 · 6 comments
Open

pio train error #19

xiongjiewu opened this issue Sep 1, 2016 · 6 comments

Comments

@xiongjiewu
Copy link

when i do pio train,it tell me:

Exception in thread "main" java.lang.IllegalStateException: No Elasticsearch client configuration detected, check your pio-env.sh forproper configuration settings
        at org.template.esClient$.client$lzycompute(esClient.scala:58)
        at org.template.esClient$.client(esClient.scala:55)
        at org.template.esClient$.hotSwap(esClient.scala:169)
        at org.template.URModel.save(URModel.scala:147)
        at org.template.URModel.save(URModel.scala:38)
        at io.prediction.controller.P2LAlgorithm.makePersistentModel(P2LAlgorithm.scala:111)
        at io.prediction.controller.Engine$$anonfun$makeSerializableModels$2.apply(Engine.scala:295)
        at io.prediction.controller.Engine$$anonfun$makeSerializableModels$2.apply(Engine.scala:294)
        at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:244)
        at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:244)
        at scala.collection.Iterator$class.foreach(Iterator.scala:727)
        at scala.collection.AbstractIterator.foreach(Iterator.scala:1157)
        at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
        at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
        at scala.collection.TraversableLike$class.map(TraversableLike.scala:244)
        at scala.collection.AbstractTraversable.map(Traversable.scala:105)
        at io.prediction.controller.Engine.makeSerializableModels(Engine.scala:294)
        at io.prediction.controller.Engine.train(Engine.scala:185)
        at io.prediction.workflow.CoreWorkflow$.runTrain(CoreWorkflow.scala:65)
        at io.prediction.workflow.CreateWorkflow$.main(CreateWorkflow.scala:247)
        at io.prediction.workflow.CreateWorkflow.main(CreateWorkflow.scala)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

here is my Elasticsearch config:

PIO_STORAGE_SOURCES_ELASTICSEARCH_TYPE=elasticsearch
PIO_STORAGE_SOURCES_ELASTICSEARCH_CLUSTERNAME=elasticsearch
PIO_STORAGE_SOURCES_ELASTICSEARCH_HOSTS=localhost
PIO_STORAGE_SOURCES_ELASTICSEARCH_PORTS=9200
PIO_STORAGE_SOURCES_ELASTICSEARCH_HOME=$PIO_HOME/vendors/elasticsearch-1.4.4

please help!

how should i do?

@xiongjiewu
Copy link
Author

@pferrel

pferrel added a commit that referenced this issue Sep 28, 2016
@ishantanu
Copy link

Elasticsearch client might be misconfigured. Might also try changing elasticsearch port to 9300. The reason might be that nodes in the elasticsearch cluster communicate with each other over port 9300 (default) whereas 9200 is for communication over HTTP interface.

@OlgaKuklina
Copy link

I have the same issue with Elasticsearch client configuration:
My Elasticsearch settings in pio-env.sh:
PIO_STORAGE_SOURCES_ELASTICSEARCH_TYPE=elasticsearch
PIO_STORAGE_SOURCES_ELASTICSEARCH_HOSTS=localhost
PIO_STORAGE_SOURCES_ELASTICSEARCH_CLUSTERNAME=pio
PIO_STORAGE_SOURCES_ELASTICSEARCH_PORTS=9300
PIO_STORAGE_SOURCES_ELASTICSEARCH_HOME=$PIO_HOME/vendors/elasticsearch-1.7.6

@ishantanu
Copy link

@OlgaKuklina Does curling localhost on port 9200 works fine?

@franmedmon
Copy link

Same issue here...

~/universal-recommender$ pio train
...
Exception in thread "main" java.lang.IllegalStateException: No Elasticsearch client configuration detected, check your pio-env.sh forproper configuration settings
        at com.actionml.EsClient$$anonfun$client$2.apply(EsClient.scala:86)
        at com.actionml.EsClient$$anonfun$client$2.apply(EsClient.scala:86)
        at scala.Option.getOrElse(Option.scala:121)
        at com.actionml.EsClient$.client$lzycompute(EsClient.scala:85)
        at com.actionml.EsClient$.client(EsClient.scala:85)
        at com.actionml.EsClient$.createIndex(EsClient.scala:174)
        at com.actionml.EsClient$.hotSwap(EsClient.scala:271)
        at com.actionml.URModel.save(URModel.scala:82)
        at com.actionml.URAlgorithm.calcAll(URAlgorithm.scala:367)
        at com.actionml.URAlgorithm.train(URAlgorithm.scala:295)
        at com.actionml.URAlgorithm.train(URAlgorithm.scala:180)
        at org.apache.predictionio.controller.P2LAlgorithm.trainBase(P2LAlgorithm.scala:49)
        at org.apache.predictionio.controller.Engine$$anonfun$18.apply(Engine.scala:690)
        at org.apache.predictionio.controller.Engine$$anonfun$18.apply(Engine.scala:690)
        at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:234)
        at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:234)
        at scala.collection.immutable.List.foreach(List.scala:381)
        at scala.collection.TraversableLike$class.map(TraversableLike.scala:234)
        at scala.collection.immutable.List.map(List.scala:285)
        at org.apache.predictionio.controller.Engine$.train(Engine.scala:690)
        at org.apache.predictionio.controller.Engine.train(Engine.scala:176)
        at org.apache.predictionio.workflow.CoreWorkflow$.runTrain(CoreWorkflow.scala:67)
        at org.apache.predictionio.workflow.CreateWorkflow$.main(CreateWorkflow.scala:251)
        at org.apache.predictionio.workflow.CreateWorkflow.main(CreateWorkflow.scala)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.apache.spark.deploy.SparkSubmit$.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:743)
        at org.apache.spark.deploy.SparkSubmit$.doRunMain$1(SparkSubmit.scala:187)
        at org.apache.spark.deploy.SparkSubmit$.submit(SparkSubmit.scala:212)
        at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:126)
        at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)

And in my pio-env.sh file:
# Elasticsearch Example
PIO_STORAGE_SOURCES_ELASTICSEARCH_TYPE=elasticsearch
PIO_STORAGE_SOURCES_ELASTICSEARCH_HOSTS=localhost
PIO_STORAGE_SOURCES_ELASTICSEARCH_PORTS=9300
PIO_STORAGE_SOURCES_ELASTICSEARCH_SCHEMES=http
PIO_STORAGE_SOURCES_ELASTICSEARCH_HOME=$PIO_HOME/vendors/elasticsearch-5.5.2

@pferrel
Copy link
Owner

pferrel commented Jan 18, 2018

Sorry this forked version is not maintained

The root version is here: https://github.com/actionml/universal-recommender

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants