| Предупреждение |
|---|
| To use the Consul service it is required realizing , the full-mesh network topology ("each-to-each" connection) of should be implemented for all the agents inside within the cluster and the for servers, when combining them into WAN. |
| Предупреждение |
|---|
| In case of distributed TM installation, it should not be prohibited using TCP and UDP between different network segments (including nodes) must be allowed in Windows firewall. |
Clustering The client collects the node and service related data and sends it to the server. System components searching for services send the request to the agent started on a local workstation, which resends the request to an available server. If the server is unable to respond the request, it can send the request to a different data center (a branch) and retrieve the respondresponse. Servers compose a cluster and define independently the leading server, responsible for elements coordination within the cluster. The first/the only one server is usually started in bootstrap mode (assigning the leader manually). When starting the agent, to connect to cluster it is enough specifying one server of this cluster. While configuring it in retry_join option, it is recommended specifying all the servers of the cluster. A quorum to held the operations and to provide the consistency is required in each data center. If there are few data centers, a separate cluster to be created in each of them. Data centers are not isolated from each other due to services detection task. An agent within one data center can get an information from a separate data center. The Consul network can use one server, but to avoid data loss it is recommended using from three to seven servers within the data center. 
Example: A cluster consisting of three nodes (servers) continues operating when one server is out of operation. Below are the examples of using the interface command line: | Command | Description |
|---|
consul members | display displays the list of cluster members list | consul | kv get –recursedisplay the cluster services list | consul kv get –recursecatalog services -node <node_name> | display displays the list of cluster | services list servers on a specific | workstationcomputer | consul operator raft list-peers -stale=true | display displays the list of all the servers regardless of the cluster |
Connecting to cluster You may register extra nodes on the cluster using one of the following ways: - Enter the command:
consul join <ip-адрес>. Please make sure, all the servers and Consul clients have the same parameters datacenter and encrypt within the consul.json configuration file (see consul.json configuration file) - Specify the list of servers, to be joined within the parameter
retry_join of consul.json configuration file.
|