首页 > 其他分享 >etcd集群搭建

etcd集群搭建

时间:2024-05-13 14:55:17浏览次数:8  
标签:urls http etcd -- 2380 集群 172.17 搭建

主机环境和分配规划:

主机ip   主机名   操作系统环境   操作系统版本
172.17.0.2 etcd01 centos 7.9
172.17.0.3 etcd02 centos 7.9
172.17.0.4 etcd03 centos 7.9

etcd官网下载,我这边下载的是v3.4.32版本https://objects.githubusercontent.com/github-production-release-asset-2e65be/11225014/219b0bb3-0a6c-4ec9-a7c3-69163804ad02?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20240511%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20240511T064321Z&X-Amz-Expires=300&X-Amz-Signature=d0282d2326d9d647c35911723fa4d9687d8269c6bd036b3314c17fc6ba5b026f&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=11225014&response-content-disposition=attachment%3B%20filename%3Detcd-v3.4.32-linux-amd64.tar.gz&response-content-type=application%2Foctet-stream

没有启用ssl部署

解压拷贝两个文件到/usr/bin/下


cp etcd /usr/bin/ && cp etcdctl /usr/bin/

直接二进制脚本启动加载配置

# etcd01
/usr/bin/etcd --name etcd1 \
--data-dir /etc/etcd/data \
--listen-client-urls http://172.17.0.2:2379 \
--advertise-client-urls http://172.17.0.2:2379 \
--listen-peer-urls http://172.17.0.2:2380 \
--initial-advertise-peer-urls http://172.17.0.2:2380 \
--initial-cluster-token etcd-cluster \
--initial-cluster "etcd1=http://172.17.0.2:2380,etcd2=http://172.17.0.3:2380,etcd3=http://172.17.0.4:2380" \
--initial-cluster-state new \
--logger zap

# etcd02
/usr/bin/etcd --name etcd2 \
--data-dir /etc/etcd/data \
--listen-client-urls http://172.17.0.3:2379 \
--advertise-client-urls http://172.17.0.3:2379 \
--listen-peer-urls http://172.17.0.3:2380 \
--initial-advertise-peer-urls http://172.17.0.3:2380 \
--initial-cluster-token etcd-cluster \
--initial-cluster "etcd1=http://172.17.0.2:2380,etcd2=http://172.17.0.3:2380,etcd3=http://172.17.0.4:2380" \
--initial-cluster-state new \
--logger zap

# etcd03
/usr/bin/etcd \
--name etcd3 \
--data-dir /etc/etcd/data \
--listen-client-urls http://172.17.0.4:2379 \
--advertise-client-urls http://172.17.0.4:2379 \
--listen-peer-urls http://172.17.0.4:2380 \
--initial-advertise-peer-urls http://172.17.0.4:2380 \
--initial-cluster-token etcd-cluster \
--initial-cluster "etcd1=http://172.17.0.2:2380,etcd2=http://172.17.0.3:2380,etcd3=http://172.17.0.4:2380" \
--initial-cluster-state new \
--logger zap

启动后检查集群状态

etcdctl --endpoints http://172.17.0.2:2380,http://172.17.0.3:2380,http://172.17.0.4:2380 endpoint health
etcdctl -w table --endpoints http://172.17.0.2:2380,http://172.17.0.3:2380,http://172.17.0.4:2380 endpoint status

 

标签:urls,http,etcd,--,2380,集群,172.17,搭建
From: https://www.cnblogs.com/zyp87/p/18189213

相关文章

  • Qwen-VL环境搭建&推理测试
    引子这几天阿里的Qwen2.5大模型在大模型圈引起了轰动,号称地表最强中文大模型。前面几篇也写了QWen的微调等,视觉语言模型也写了一篇CogVLM,感兴趣的小伙伴可以移步https://blog.csdn.net/zzq1989_/article/details/138118608?spm=1001.2014.3001.5501。前面也写过一篇智谱AI的视觉......
  • k3s集群默认config不在~/.kube/
    在K3s安装的集群上,kubeconfig文件通常位于服务器的/etc/rancher/k3s/k3s.yaml路径下。这个文件包含了连接到Kubernetes集群所需的配置信息,包括集群的服务器地址、CA证书、用户凭证等。找到kubeconfig文件:登录到K3s服务器,检查/etc/rancher/k3s/k3s.yaml文件是否存在。您可以使......
  • 域搭建
    1.什么是域?一种用于管理计算机组的网络结构,一个域的组成大致分为域控机(DC)和用户机。2.搭建过程我使用的虚拟机镜像为Windowsserver2016和window10EducationEdition。搭建的域环境包括一个域树和一个单域,域树中包含两个子域,网络拓补图如下。2.1.父域控制器搭建需要......
  • yum仓库搭建
    yum仓库搭建目录yum仓库搭建一、yum仓库简介二、准备安装源1、软件仓库的提供方式2、RPM软件包的来源3、构建centos7软件仓库4、在软件仓库中加入非官方RPM包组三、搭建本地yum仓库1、实例四、ftp搭建yum仓库4.1、服务端4.2、客户端4.3、实例:4.3.1服务端4.3.2客户端五、http......
  • [附源码]新天龙八部3永恒经典之江山策仿官方_联网+单机搭建架设教程
    新天龙八部3永恒经典之江山策仿官_联网架设搭建_附赠GM工具+视频教程本教程仅限学习使用,禁止商用,一切后果与本人无关,此声明具有法律效应!!!!教程是本人亲自搭建成功的,绝对是完整可运行的,踩过的坑都给你们填上了。如果你是小白也没问题,跟着教程走也是可以搭建成功的,但是一定要有耐心......
  • FM20S用户手册-Linux开发环境搭建
     ......
  • 网易Airtest集群方案大揭秘:小型便携式集群方案来啦
    此文章来源于项目官方公众号:“AirtestProject”版权声明:允许转载,但转载必须保留原链接;请勿用作商业或者非法用途一、前言中小型企业/工作室搭建便携设备集群的制胜法宝是什么?当然非网易Airtest便携式机柜莫属啦。得益于广大企业客户对我们便携式集群的支持,我们团队也一直在坚......
  • centos7下redis集群部署
    1、环境准备安装redis所需依赖环境#在线:yum-yinstallepel-releasegcc #离线:#下载yuminstall--downloadonly--downloaddir=/home/filesepel-releasegcc#将依赖包放到离线服务器,进入目录cd/home/files#执行安装rpm-Uvh./*.rpm--node......
  • 准实时数仓搭建指南:以仓储式会员商超为模拟场景
    在电商和新零售持续冲击传统零售商超的今天,仓储式会员店反而成功逃脱曾经的“水土不服”预测,业绩一路向好。与此同时,随着人工智能、大数据、智慧物流等技术的不断革新,零售批发的消费场景也进一步拓展,对数据分析的要求也越发迫切。本文将以巴基斯坦Metro的数仓项目为例,以操作指......
  • qgroundcontrol开发环境搭建源码编译
    qgroundcontrol是一款无人机地面站开源软件,C++/QT开发在https://github.com/mavlink/qgroundcontrol上就能找到,选择稳定版下载最新的是2.6下载https://github.com/mavlink/qgroundcontrol/archive/Stable_V2.6.zipQT的对应版本http://download.qt-project.org/official_releas......