I was through direct yum install ( yum install etcd -y
), which generated configuration file /etc/etcd/etcd.conf
.
Here sub-clusters and stand-alone version to introduce configuration items
Stand-alone configuration
ETCD_DATA_DIR
: Data storage path, do not modify the default, of course, also be present elsewhere; ETCD_WAL_DIR
: The default is empty, set the path, you can write WAL alternative data file is written, the operating loss with less risk; ETCD_LISTEN_CLIENT_URLS
: URL inform the client, because of its exposure to the RESTFUL API, for interacting, cloud server attention to the internal network ip + 2379 (default listen port), do not set it, other hosts can not access the large column etcd installed deployment steps ; : ETCD_ADVERTISE_CLIENT_URLS
the URL of informing the client, set and to the same one;
Cluster configuration
ETCD_INITIAL_ADVERTISE_PEER_URLS
: Inform the other nodes of the cluster URL, typically port 2380;ETCD_INITIAL_CLUSTER
: Cluster node information such asnode1=http://119.29.155.122:2380
;ETCD_INITIAL_CLUSTER_TOKEN
: Custom a token;ETCD_INITIAL_CLUSTER_STATE
: There are twonew
andexisting
that added with the added;
After configured, you can use the remote client or etcdctl to use the etcd related functions.