Restoreedit

actions:
  1:
    action: restore
    description: >-
      Restore all indices in the most recent snapshot with state SUCCESS.  Wait
      for the restore to complete before continuing.  Do not skip the repository
      filesystem access check.  Use the other options to define the index/shard
      settings for the restore.
    options:
      repository:
      # Leaving name blank will result in restoring the most recent snapshot by age
      name:
      # Leaving indices blank will result in restoring all indices in the snapshot
      indices:
      include_aliases: False
      ignore_unavailable: False
      include_global_state: True
      partial: False
      rename_pattern:
      rename_replacement:
      extra_settings:
      wait_for_completion: True
      skip_repo_fs_check: False
      timeout_override:
      continue_if_exception: False
      disable_action: False
    filters:
    - filtertype: state
      state: SUCCESS
      exclude:
    - filtertype: ...
Note

Empty values and commented lines will result in the default value, if any, being selected. If a setting is set, but not used by a given action, it will be ignored.

This action will restore indices from the indicated repository, from the most recent snapshot identified by the applied filters, or the snapshot identified by name.

The other options are usually okay to leave at the defaults, but feel free to read about them and change them accordingly.

The extra_settings option allows the addition of extra settings, such as index settings and mappings. An example of how these settings can be used to change settings for an index being restored might be:

extra_settings:
  settings:
    number_of_shards: 1
    number_of_replicas: 0
  mappings:
    type1 :
      properties:
        field1:
          type: string
          index: not_analyzed

Required settingsedit

Optional settingsedit

Tip

See an example of this action in an actionfile here.