2018-10-16 15:18:54 -04:00
|
|
|
[role="xpack"]
|
|
|
|
[testenv="basic"]
|
|
|
|
[[ilm-stop]]
|
2018-12-20 16:34:11 -05:00
|
|
|
=== Stop {ilm} API
|
2019-04-30 13:46:13 -04:00
|
|
|
|
|
|
|
[subs="attributes"]
|
2018-10-16 15:18:54 -04:00
|
|
|
++++
|
2018-12-20 16:34:11 -05:00
|
|
|
<titleabbrev>Stop {ilm}</titleabbrev>
|
2018-10-16 15:18:54 -04:00
|
|
|
++++
|
|
|
|
|
2018-12-20 16:34:11 -05:00
|
|
|
Stop the {ilm} ({ilm-init}) plugin.
|
2018-10-16 15:18:54 -04:00
|
|
|
|
2019-11-20 11:19:33 -05:00
|
|
|
[[ilm-stop-request]]
|
|
|
|
==== {api-request-title}
|
2018-10-16 15:18:54 -04:00
|
|
|
|
|
|
|
`POST /_ilm/stop`
|
|
|
|
|
2019-11-20 11:19:33 -05:00
|
|
|
[[ilm-stop-prereqs]]
|
|
|
|
==== {api-prereq-title}
|
|
|
|
|
|
|
|
* If the {es} {security-features} are enabled, you must have the `manage_ilm`
|
|
|
|
cluster privilege to use this API. For more information, see
|
|
|
|
<<security-privileges>>.
|
|
|
|
|
|
|
|
[[ilm-stop-desc]]
|
|
|
|
==== {api-description-title}
|
2018-10-16 15:18:54 -04:00
|
|
|
|
2018-12-20 16:34:11 -05:00
|
|
|
Halts all lifecycle management operations and stops the {ilm-init} plugin. This
|
|
|
|
is useful when you are performing maintenance on the cluster and need to prevent
|
|
|
|
{ilm-init} from performing any actions on your indices.
|
2018-11-08 18:26:27 -05:00
|
|
|
|
|
|
|
The API returns as soon as the stop request has been acknowledged, but the
|
|
|
|
plugin might continue to run until in-progress operations complete and the plugin
|
2020-04-28 19:38:01 -04:00
|
|
|
can be safely stopped. Use the <<ilm-get-status, Get {ilm-init} Status>> API to see
|
2018-12-20 16:34:11 -05:00
|
|
|
if {ilm-init} is running.
|
2018-10-16 15:18:54 -04:00
|
|
|
|
2019-11-20 11:19:33 -05:00
|
|
|
[[ilm-stop-query-params]]
|
|
|
|
==== {api-query-parms-title}
|
2018-10-16 15:18:54 -04:00
|
|
|
|
2019-08-02 08:42:33 -04:00
|
|
|
include::{docdir}/rest-api/common-parms.asciidoc[tag=timeoutparms]
|
2018-10-16 15:18:54 -04:00
|
|
|
|
2019-11-20 11:19:33 -05:00
|
|
|
[[ilm-stop-example]]
|
|
|
|
==== {api-examples-title}
|
2018-10-16 15:18:54 -04:00
|
|
|
|
2020-04-28 19:38:01 -04:00
|
|
|
The following example stops the {ilm-init} plugin.
|
2018-10-16 15:18:54 -04:00
|
|
|
|
|
|
|
//////////////////////////
|
|
|
|
|
2019-09-09 13:38:14 -04:00
|
|
|
[source,console]
|
2018-10-16 15:18:54 -04:00
|
|
|
--------------------------------------------------
|
2018-10-30 19:19:05 -04:00
|
|
|
PUT _ilm/policy/my_policy
|
2018-10-16 15:18:54 -04:00
|
|
|
{
|
|
|
|
"policy": {
|
|
|
|
"phases": {
|
|
|
|
"warm": {
|
2018-10-30 15:54:02 -04:00
|
|
|
"min_age": "10d",
|
2018-10-16 15:18:54 -04:00
|
|
|
"actions": {
|
|
|
|
"forcemerge": {
|
|
|
|
"max_num_segments": 1
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"delete": {
|
2018-10-30 15:54:02 -04:00
|
|
|
"min_age": "30d",
|
2018-10-16 15:18:54 -04:00
|
|
|
"actions": {
|
|
|
|
"delete": {}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
PUT my_index
|
|
|
|
--------------------------------------------------
|
|
|
|
// TEST
|
|
|
|
|
|
|
|
//////////////////////////
|
|
|
|
|
2019-09-09 13:38:14 -04:00
|
|
|
[source,console]
|
2018-10-16 15:18:54 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
POST _ilm/stop
|
|
|
|
--------------------------------------------------
|
|
|
|
// TEST[continued]
|
|
|
|
|
|
|
|
If the request does not encounter errors, you receive the following result:
|
|
|
|
|
2019-09-06 09:22:08 -04:00
|
|
|
[source,console-result]
|
2018-10-16 15:18:54 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
{
|
|
|
|
"acknowledged": true
|
|
|
|
}
|
|
|
|
--------------------------------------------------
|
2018-10-24 08:05:41 -04:00
|
|
|
|
|
|
|
//////////////////////////
|
|
|
|
|
2019-09-09 13:38:14 -04:00
|
|
|
[source,console]
|
2018-10-24 08:05:41 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
POST _ilm/start
|
|
|
|
--------------------------------------------------
|
|
|
|
// TEST[continued]
|
|
|
|
|
|
|
|
//////////////////////////
|