yaoxingcheng / TLM

ICML'2022: NLP From Scratch Without Large-Scale Pretraining: A Simple and Efficient Framework
MIT License
256 stars 21 forks source link

encounter ConnectionError when executing data_selection.sh #13

Closed fernando9torres closed 8 months ago

fernando9torres commented 2 years ago

Hi Xingcheng, thanks for the great work and releasing the code.

I first download and run ./bin/elasticsearch, then execute bash example_scripts/data_selection.sh. But I've encountered an error: elasticsearch.exceptions.ConnectionError: ConnectionError(('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))) caused by: ProtocolError(('Connection aborted.', RemoteDisconnected('Remote end closed connection without response')))

Could you help me to fix this error? Is there anything I missed about elasticsearch?

yaoxingcheng commented 2 years ago

Hi. I'm sorry have no clear recollection about this error in my experience. My suggestions are

  1. Make sure elasticsearch is really started after executing ./bin/elasticsearch by curl localhost:9200.
  2. Make sure elasticsearch is hosted on the same port with the client in the data selection script (port 9200 by default).
fernando9torres commented 2 years ago

Thanks for the quick reply!

curl only gets curl: (52) Empty reply from server, and elasticsearch returns: [2022-03-08T02:58:46,651][WARN ][o.e.x.s.t.n.SecurityNetty4HttpServerTransport] received plaintext http traffic on an https channel, closing connection Netty4HttpChannel{localAddress=/127.0.0.1:9200, remoteAddress=/127.0.0.1:53090}

It seems that elasticsearch is not started. I found this answer. So do I need to install Kibana too?

sunyilgdx commented 2 years ago

Hi Xingcheng, thanks for the great work and releasing the code.

I first download and run ./bin/elasticsearch, then execute bash example_scripts/data_selection.sh. But I've encountered an error: elasticsearch.exceptions.ConnectionError: ConnectionError(('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))) caused by: ProtocolError(('Connection aborted.', RemoteDisconnected('Remote end closed connection without response')))

Could you help me to fix this error? Is there anything I missed about elasticsearch?

Just make some change on the file 'config/elasticsearch.yml'

xpack.security.enabled: false
xpack.security.enrollment.enabled: false
xpack.security.http.ssl:
  enabled: false
xpack.security.transport.ssl:
  enabled: false

Don't know why, but works.