Member since
09-06-2016
1
Post
0
Kudos Received
0
Solutions
09-06-2016
09:26 AM
The reason in 2 records in /etc/hosts for node1: cat /etc/hosts
127.0.0.1 node1 node1
## vagrant-hostmanager-start
192.168.66.121 node1
## vagrant-hostmanager-end
127.0.0.1 localhost
For python requests package node1 is resolved as 127.0.0.1 and it gets "socket.error: [Errno 111] Connection refused" For curl (and I believe for browser) node1 is resolved as below: [vagrant@node1 ~]$ curl -v http://node1:9200/_cat/health
* About to connect() to node1 port 9200 (#0)
* Trying 127.0.0.1... Connection refused
* Trying 192.168.66.121... connected
* Connected to node1 (192.168.66.121) port 9200 (#0)
To fix it you can just remove "127.0.0.1 node1 node1" from /etc/hosts and run "vagrant provision" again
... View more