---
name: "Search::Elasticsearch::Client::7_0::Direct::ILM"
section: "3pm"
platform: "linux"
package: "libsearch-elasticsearch-perl"
version: "7.30-1"
release: "Debian 11 (Bullseye)"
platforms: ["linux"]
url: "https://new.carta.tech/Search::Elasticsearch::Client::7_0::Direct::ILM"
---

# Search::Elasticsearch::Client::7\_0::Direct::ILM(3pm)

Plugin providing index lifecycle management APIs for Search::Elasticsearch 7.x

## NAME

Search::Elasticsearch::Client::7\_0::Direct::ILM - Plugin providing index lifecycle management APIs for Search::Elasticsearch 7.x

## VERSION

version 7.30

### DESCRIPTION

This module provides methods to use the index lifecycle management feature.

The full documentation for ILM is available here: \<https://www.elastic.co/guide/en/elasticsearch/reference/current/index-lifecycle-management.html\>

## POLICY METHODS

### "put\_lifecycle()"

```
    $response = $es->ilm->put_lifecycle(
        policy  => $policy  # required
        body    => {...}    # required
    )
```

The `"put_lifecycle()"` method creates or updates a lifecycle policy.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM put\_lifecycle docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-put-lifecycle.html\> for more information.

### "put\_lifecycle()"

```
    $response = $es->ilm->put_lifecycle(
        policy  => $policy  # required
        body    => {...}    # required
    )
```

The `"put_lifecycle()"` method creates or updates a lifecycle policy.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM put\_lifecycle docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-put-lifecycle.html\> for more information.

### "get\_lifecycle()"

```
    $response = $es->ilm->get_lifecycle(
        policy  => $policy  # required
    )
```

The `"get_lifecycle()"` method retrieves the specified policy

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM get\_lifecycle docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-get-lifecycle.html\> for more information.

### "delete\_lifecycle()"

```
    $response = $es->ilm->delete_lifecycle(
        policy  => $policy  # required
    )
```

The `"delete_lifecycle()"` method deletes the specified policy

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM delete\_lifecycle docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-remove-lifecycle.html\> for more information.

## INDEX MANAGEMENT METHODS

### "move\_to\_step()"

```
    $response = $es->ilm->move_to_step(
        index  => $index,       # required
        body   => {...}         # required
    )
```

The `"move_to_step()"` method triggers execution of a specific step in the lifecycle policy.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM move\_to\_step docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-move-to-step.html\> for more information.

### "retry()"

```
    $response = $es->ilm->retry(
        index  => $index,       # required
    )
```

The `"retry()"` method retries executing the policy for an index that is in the ERROR step.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM retry docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-retry.html\> for more information.

### "remove\_lifecycle()"

```
    $response = $es->ilm->remove_lifecycle(
        index  => $index  # required
    )
```

The `"remove_lifecycle()"` method removes a lifecycle from the specified index.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM remove\_lifecycle docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-remove-lifecycle.html\> for more information.

### "explain\_lifecycle()"

```
    $response = $es->ilm->explain_lifecycle(
        index  => $index  # required
    )
```

The `"explain_lifecycle()"` method returns information about the index’s current lifecycle state.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM explain\_lifecycle docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-explain-lifecycle.html\> for more information.

## OPERATION MANAGEMENT APIS

### "status()"

```
    $response = $es->ilm->status;
```

The `"status()"` method returns the current operating mode for ILM.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM status docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-get-status.html\> for more information.

### "start()"

```
    $response = $es->ilm->start;
```

The `"start()"` method starts the index lifecycle management process.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM start docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-start.html\> for more information.

### "stop()"

```
    $response = $es->ilm->stop;
```

The `"stop()"` method stops the index lifecycle management process.

Query string parameters:\
     `"error_trace"`,\
     `"filter_path"`,\
     `"human"`

See the ILM stop docs \<https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-stop.html\> for more information.

## AUTHOR

Enrico Zimuel \<enrico.zimuel@elastic.co\>

## COPYRIGHT AND LICENSE

This software is Copyright (c) 2020 by Elasticsearch BV.

This is free software, licensed under:

```
  The Apache License, Version 2.0, January 2004
```
