mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-04-25 07:37:19 -04:00
* Put Shutdown API docs * Get Shutdown API docs * Properly escape regex * Doc tests build now! (but don't pass) * Doc tests pass now! (with a code fix that will go in a different PR) * DELETE shutdown docs * Edit for language & consistency * Fix doctest * Add cloud-only banner * Add allocation_delay docs * Restore file that got deleted somehow? * Use `restart` type in example to demonstrate `allocation_delay` param * Fix typo per review Co-authored-by: debadair <debadair@elastic.co> * Vastly improve wording per review Co-authored-by: debadair <debadair@elastic.co> * Adjust test request & response so it passes Co-authored-by: Deb Adair <debadair@elastic.co> Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
77 lines
2 KiB
Text
77 lines
2 KiB
Text
[[delete-shutdown]]
|
|
=== Delete shutdown API
|
|
|
|
NOTE: {cloud-only}
|
|
|
|
Cancels shutdown preparations or clears a shutdown request
|
|
so a node can resume normal operations.
|
|
|
|
[[delete-shutdown-api-request]]
|
|
==== {api-request-title}
|
|
|
|
`DELETE _nodes/<node-id>/shutdown`
|
|
|
|
[[delete-shutdown-api-prereqs]]
|
|
==== {api-prereq-title}
|
|
|
|
* If the {es} {security-features} are enabled, you must have the `manage`
|
|
<<privileges-list-cluster,cluster privilege>> to use this API.
|
|
|
|
* If the <<operator-privileges,{operator-feature}>> is enabled,
|
|
you must be an operator to use this API.
|
|
|
|
[[delete-shutdown-api-desc]]
|
|
==== {api-description-title}
|
|
|
|
Enables a node to resume normal operations following a
|
|
<<put-shutdown, put shutdown>> request.
|
|
You must explicitly clear the shutdown request when a node rejoins the cluster,
|
|
regardless of the shutdown type.
|
|
|
|
|
|
[[delete-shutdown-api-path-params]]
|
|
==== {api-path-parms-title}
|
|
|
|
`<node-id>`::
|
|
(Optional, string)
|
|
The ID of a node that you prepared for shut down.
|
|
|
|
[[delete-shutdown-api-params]]
|
|
==== {api-query-parms-title}
|
|
|
|
include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=timeoutparms]
|
|
|
|
[[delete-shutdown-api-example]]
|
|
==== {api-examples-title}
|
|
|
|
Prepare a node to be restarted:
|
|
|
|
[source,console]
|
|
--------------------------------------------------
|
|
PUT /_nodes/USpTGYaBSIKbgSUJR2Z9lg/shutdown
|
|
{
|
|
"type": "restart",
|
|
"reason": "Demonstrating how the node shutdown API works"
|
|
}
|
|
--------------------------------------------------
|
|
// TEST[setup:node]
|
|
// TEST[s/USpTGYaBSIKbgSUJR2Z9lg/\$node_name/]
|
|
|
|
Cancel the shutdown preparations or clear the shutdown request
|
|
after restarting:
|
|
|
|
[source,console]
|
|
--------------------------------------------------
|
|
DELETE /_nodes/USpTGYaBSIKbgSUJR2Z9lg/shutdown
|
|
--------------------------------------------------
|
|
// TEST[continued]
|
|
// TEST[s/USpTGYaBSIKbgSUJR2Z9lg/\$node_name/]
|
|
|
|
Which returns the following response:
|
|
|
|
[source,console-result]
|
|
--------------------------------------------------
|
|
{
|
|
"acknowledged": true
|
|
}
|
|
--------------------------------------------------
|