Curator execution doesnt seem to give any output


(Daniel Braga) #1

Hello. I have installed curator (5.4.1) on one of my elatic nodes. When i try to run the following command (with or without the --dry-install) there is no output nor logs. Any ideas? It follows my config and action files as well.
curator --config curator.yml --dry-run ACTION_FILE.yml

curator.yml

    client:
  hosts:
  - 127.0.0.1
port: 9200
url_prefix:
  use_ssl: False
  certificate:
  client_cert:
  client_key:
  ssl_no_validate: False
  http_auth:
  timeout: 30
  master_only: False

logging:
  loglevel: DEBUG
  logfile:/CA/curator/log.log
  logformat: default
  blacklist: ['elasticsearch', 'urllib3']

ACTION_FILE.yml

  action: delete_indices
     description:
    options:
      ignore_empty_list: True
      disable_action: False
    filters:
    - filtertype: pattern
      kind: prefix
      value: metricbeat-
    - filtertype: age
      source: name
      direction: older
      timestring: '%Y.%m.%d'
      unit: days
      unit_count: 5


(Aaron Mildenstein) #2

I can’t tell if your configuration files are properly formatted and indented. Please edit and encapsulate your config files in triple back-ticks:

```
Paste here
```

(Pjanzen) #3

Look likes a typo there? the ' just after logfile:


(Aaron Mildenstein) #4

Not having a closing quote would do it


(andy_zhou) #5

like this: this is a fire not a directory
logfile: /root/.curator/log.log


(Aaron Mildenstein) #6

Not to mention that CA would seem to indicate a Certificate Authority. Are you sure that's where you want your logs to go?


(Daniel Braga) #7

Thanks. I have just done that.


(Daniel Braga) #8

despite fixing that entry, the error persists . Curator itself seems to be working fine. It shows an error if i dont inform the action file, for example. So in short, it seems to run but it does nothing and it doesnt display any output.


(Daniel Braga) #9

CA means something else actually. I am using it only as the location for the curator application now.


(Aaron Mildenstein) #10

Your action file YAML is formatted and indented incorrectly. It should be:

actions:
  1:
    action: delete_indices
      description:
    options:
      ignore_empty_list: True
      disable_action: False
    filters:
    - filtertype: pattern
      kind: prefix
      value: metricbeat-
    - filtertype: age
      source: name
      direction: older
      timestring: '%Y.%m.%d'
      unit: days
      unit_count: 5

(Daniel Braga) #11

Thanks @theuntergeek. I have tried again with your setup, unfortunatelly the issue persists. I wonder if there is a way to debug the error....It follows the action file again....

actions:
  1:
    action: delete_indices
      description:
    options:
      ignore_empty_list: True
      disable_action: False
    filters:
    - filtertype: pattern
      kind: prefix
      value: filebeat-
    - filtertype: age
      source: name
      direction: older
      timestring: '%Y.%m.%d'
      unit: days
      unit_count: 5

(Aaron Mildenstein) #12

Thank you for encapsulating your curator.yml file. When I see this:

I still see improperly formatted YAML.

You should have this file formatted more like:

client:
  hosts: [ "127.0.0.1" ]
  port: 9200
  url_prefix:
  use_ssl: False
  certificate:
  client_cert:
  client_key:
  ssl_no_validate: False
  http_auth:
  timeout: 30
  master_only: False

logging:
  loglevel: DEBUG
  logfile:/CA/curator/log.log
  logformat: default
  blacklist: ['elasticsearch', 'urllib3']

(Daniel Braga) #13

just tried what you suggested. no deal.

I wonder if the problem is more elemental. For example, maybe is not accepting the host name. I am logged on one of the cluster nodes, so i tried a varierty of changes, like using the ip of the current node, the other node, and both. No luck :frowning:

client:
  hosts: [ "127.0.0.1" ]
  port: 9200
  url_prefix:
  use_ssl: False
  certificate:
  client_cert:
  client_key:
  ssl_no_validate: False
  http_auth:
  timeout: 30
  master_only: False

logging:
  loglevel: DEBUG
  logfile:/CA/curator/log.log
  logformat: default
  blacklist: ['elasticsearch', 'urllib3']

(Daniel Braga) #14

one more question. can i use the clustar.name on the hosts field?


(Aaron Mildenstein) #15

Should have a space, and possibly quotes:

logfile: "/CA/curator/log.log"

Does the user have write access to this file?


(Daniel Braga) #16

bingo!
I feel embarassed about that. thank you very much @theuntergeek for all the help


(system) #17

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