Not able to fire command for curator


(Vikas Gopal) #1

Hi Experts ,

Recently I have installed curator to manage indices on windows machine and I am using elasticsearch1.6.0 with shield .I have 6 indices in ES and i want to show them using curator.

In cmd i just typed "curator show indices --all-indices" .It gives me below error

2015-07-04 14:16:55,321 INFO Job starting: show indices
ERROR: Connection failure.

Seems curator is not able to set connection with ES.Please suggest what needs to be done here .

Regards
Vikas


(Magnus Bäck) #2

Curator probably defaults to localhost:9200. Is that where your Elasticsearch instance runs? Any firewall that might be blocking the connection?


(Vikas Gopal) #3

Thanks Magnus,

Yes I am running ES on localhost only . Since I am doing testing so I am using a single windows machine , so I do not think this is the firewall issue as ES works fine on 9200 port . A quick question , do I run curator command in any specific folder as I am running it directly in C: drive (but my ES is in E drive) .
I am running curator command something like

C:\Users\vikas.g>curator show indices --all-indices
2015-07-04 18:34:29,355 INFO Job starting: show indices
ERROR: Connection failure.


(Magnus Bäck) #4

It doesn't matter in which directory you run Curator. Can you connect to localhost:9200 with e.g. telnet or a web browser? You say you're using Shield—perhaps you need to authenticate?


(Vikas Gopal) #5

Even I was thinking that may be shield is the reason , but I close everything then again launch ES, provided user name and password (admin user with admin privilege), ES works fine. Then I retried curator command. Still same error .


(Magnus Bäck) #6

I repeat, can you connect to localhost:9200 with e.g. telnet or a web browser?

I haven't used Shield, but wouldn't Curator have to authenticate rather than ES itself?


(Vikas Gopal) #7

Yes I am able to connect to localhost:9200 with browser . Yes it does ask me user name and password , once entered I am able to connect to localhost:9200.


(Aaron Mildenstein) #8

You will need the --http_auth[1] flag, and maybe the --use_ssl[2] flag

[1]https://www.elastic.co/guide/en/elasticsearch/client/curator/current/http_auth.html
[2]https://www.elastic.co/guide/en/elasticsearch/client/curator/current/use_ssl.html


(Vikas Gopal) #9

Thanks Aaron,

I tried following but same result.

C:\Windows\system32>curator --host localhost --port 9200 --http_auth user:admin show indices --all-indices
2015-07-04 19:17:18,237 INFO Job starting: show indices
ERROR: Connection failure.


(Vikas Gopal) #10

Wow !!! it works like charm ...
I was mentioning wrong username, my bad (I must say we should not work on Saturday's) ....so it works with --http_auth flag.

Thanks again


(Chaz McCluein) #11

Do you know how I can change make curator default to something other than localhost? Localhost is not accessible for me.


(Magnus Bäck) #12

@McCluein—please start your own thread for your unrelated question.


(system) #13