mirror of https://github.com/hashicorp/consul
36 lines
1.3 KiB
Plaintext
36 lines
1.3 KiB
Plaintext
---
|
|
layout: "docs"
|
|
page_title: "Commands: Force Leave"
|
|
sidebar_current: "docs-commands-forceleave"
|
|
description: |-
|
|
The `force-leave` command forces a member of a Consul cluster to enter the left state. If the member is still actually alive, it will eventually rejoin the cluster. The true purpose of this method is to force remove failed nodes.
|
|
---
|
|
|
|
# Consul Force Leave
|
|
|
|
Command: `consul force-leave`
|
|
|
|
The `force-leave` command forces a member of a Consul cluster to enter the
|
|
"left" state. If the member is still actually alive, it will
|
|
eventually rejoin the cluster. The true purpose of this method is to force
|
|
remove "failed" nodes.
|
|
|
|
Consul periodically tries to reconnect to "failed" nodes in case it is a
|
|
network partition. After some configured amount of time (by default 72 hours),
|
|
Consul will reap "failed" nodes and stop trying to reconnect. The `force-leave`
|
|
command can be used to transition the "failed" nodes to "left" nodes more
|
|
quickly.
|
|
|
|
This can be particularly useful for a node that was running as a server,
|
|
as it will be removed from the Raft quorum. Note that `force-leave` cannot be
|
|
used to force removal of nodes that are outside of the datacenter.
|
|
|
|
## Usage
|
|
|
|
Usage: `consul force-leave [options] node`
|
|
|
|
#### API Options
|
|
|
|
<%= partial "docs/commands/http_api_options_client" %>
|
|
|