elasticsearch/docs/reference/shutdown/apis/shutdown-delete.asciidoc
Liam Thompson 33a71e3289
[DOCS] Refactor book-scoped variables in docs/reference/index.asciidoc (#107413)
* Remove `es-test-dir` book-scoped variable

* Remove `plugins-examples-dir` book-scoped variable

* Remove `:dependencies-dir:` and `:xes-repo-dir:` book-scoped variables

- In `index.asciidoc`, two variables (`:dependencies-dir:` and `:xes-repo-dir:`) were removed.
- In `sql/index.asciidoc`, the `:sql-tests:` path was updated to fuller path
- In `esql/index.asciidoc`, the `:esql-tests:` path was updated idem

* Replace `es-repo-dir` with `es-ref-dir`

* Move `:include-xpack: true` to few files that use it, remove from index.asciidoc
2024-04-17 14:37:07 +02:00

78 lines
2.1 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,
or when a node has permanently left the cluster. Shutdown requests are never
removed automatically by {es}.
[[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-ref-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
}
--------------------------------------------------