大数据全系列 教程
1869个小节阅读:465.2k
目录
JAVA全系列 教程
面向对象的程序设计语言
Python全系列 教程
Python3.x版本,未来主流的版本
人工智能 教程
顺势而为,AI创新未来
大厂算法 教程
算法,程序员自我提升必经之路
C++ 教程
一门通用计算机编程语言
微服务 教程
目前业界流行的框架组合
web前端全系列 教程
通向WEB技术世界的钥匙
大数据全系列 教程
站在云端操控万千数据
AIGC全能工具班
A A
White Night
注意:一定要使用ningx 1.9以上版本!
下载consul_0.7.5_linux_amd64.zip
xxxxxxxxxx
[root@node1 ~]# cd /opt/apps/
[root@node1 apps]# wget https://releases.hashicorp.com/consul/0.7.5/consul_0.7.5_linux_amd64.zip
或者使用提供的软件上传即可。
安装unzip
xxxxxxxxxx
[root@node1 apps]# yum install unzip -y
解压consul_0.7.5_linux_amd64.zip,并将解压文件移动到/opt目录
xxxxxxxxxx
[root@node1 apps]# unzip consul_0.7.5_linux_amd64.zip
Archive: consul_0.7.5_linux_amd64.zip
inflating: consul
[root@node1 apps]# mv consul /opt/
[root@node1 apps]# cd /opt/
[root@node1 opt]# ll
总用量 35160
drwxr-xr-x. 3 root root 89 8月 3 17:25 apps
-rwxr-xr-x. 1 root root 36003713 2月 15 2017 consul
测试consul是否可以正常使用
xxxxxxxxxx
[root@node1 opt]# ./consul
usage: consul [--version] [--help] <command> [<args>]
Available commands are:
agent Runs a Consul agent
configtest Validate config file
event Fire a new event
exec Executes a command on Consul nodes
force-leave Forces a member of the cluster to enter the "left" state
info Provides debugging information for operators
join Tell Consul agent to join cluster
keygen Generates a new encryption key
keyring Manages gossip layer encryption keys
kv Interact with the key-value store
leave Gracefully leaves the Consul cluster and shuts down
lock Execute a command holding a lock
maint Controls node or service maintenance mode
members Lists the members of a Consul cluster
monitor Stream logs from a Consul agent
operator Provides cluster-level tools for Consul operators
reload Triggers the agent to reload configuration files
rtt Estimates network round trip time between nodes
snapshot Saves, restores and inspects snapshots of Consul server state
version Prints the Consul version
watch Watch for changes in Consul
说明可以正常使用。
启动consul
xxxxxxxxxx
[root@node1 opt]# ./consul agent -dev -ui -node=consul-dev -client=192.168.20.101