2023-01-13 LightDB分布式部署.md

这篇具有很好参考价值的文章主要介绍了2023-01-13 LightDB分布式部署.md。希望对大家有所帮助。如果存在错误或未考虑完全的地方,请大家不吝赐教,您也可以点击"举报违法"按钮提交疑问。

LightDB分布式部署

  • 分布式部署模式
# 1.常规模式
    1台服务器作为协调者节点,N(N>1)台服务器作为工作节点,每个节点都按照高可用方式进行部署
    比如,一个协调节点,2个工作节点,
    * 工作节点按照一主一从高可用方式部署,则一共需要[(1+2)*2=6台]服务器
    * 工作节点按照一主一从一witness方式部署,则一共需要[(1+2)*3=9台]服务器    
# 2.多机单实例
    1台服务器作为协调者节点,N(N>1)台服务器作为工作节点,每个节点都按照单机模式部署
# 3.单机多实例
    使用1台服务器同时安装协调者节点和工作节点的实例,所有实例均按照单机模式部署

生产环境仅建议使用常规模式部署。
  • 常规模式部署

1.服务器列表文章来源地址https://www.toymoban.com/news/detail-505363.html

1. 182.168.121.211
2. 182.168.121.212
3. 182.168.121.213
4. 182.168.121.214
5. 182.168.121.215
6. 182.168.121.216
  • 命令行安装
[lightdb@localhost lightdb-x-13.8-22.3-7953-el7.x86_64]$ pwd
/home/lightdb/lightdb-x-13.8-22.3-7953-el7.x86_64
[lightdb@localhost lightdb-x-13.8-22.3-7953-el7.x86_64]$ ls
install.sh  jdk  lightdb-installer-13.8-22.3.jar  lightdb-uninstaller-13.8-22.3.jar  lightdb-x  log  script  system-lib
[lightdb@localhost lightdb-x-13.8-22.3-7953-el7.x86_64]$ 

# 1.执行install.sh
[lightdb@localhost lightdb-x-13.8-22.3-7953-el7.x86_64]$ ./install.sh
Whether to use the graphical user interface (GUI, Make sure DISPLAY is configured, Such as [export DISPLAY=127.0.0.1:0.0])?(Yes or No)
no
Choice a kind of configuration mode!
1: Only install.
2: Install database and Create instance.
3: Developer
Please enter 1 2 or 3(The default is 1):
2
Choice a kind of install mode!

1: Single Mode.
2: High Availability Mode
3: Distributed Mode
Please enter 1, 2 or 3:(The default is 1)
3
Please select distributed mode!
Please enter distributed mode:
1 Normal mode;
2 Multi-server single instance;
3 Single server multi-instance.(Default 1)
1
Config Server for High Availability Mode!
Please enter coordinator node:----配置CN节点
Please enter a virtual IP address with network, such as (192.168.217.234/16):
192.168.121.201/24
The cluster need a primary server(required), one or more standby server(optional) and a witness server(optional).
Please input a primary server ip which is actually the ip of the current server(required). such as (192.168.217.234/16):
192.168.121.211/24 ---CN主节点
Please input a standby server ip(required), such as (192.168.217.234/16):
192.168.121.212/24 ---CN从节点
Please enter status of the standby server [192.168.121.212]
1 sync:
2 async:
1
Continue to add standby nodes?(enter [exit] to left.):
exit
Please input a witness server ip(optional), such as (192.168.217.234/16):
                    ----此处先不配置witness节点
Witness is empty
Please enter a port of the cluster. (Default port 5432):

======================================= Servers =======================================
Vip: 192.168.121.201
Port: 5432
Ip: 192.168.121.211 Role: primary Status: none
Ip: 192.168.121.212 Role: standby Status: sync
======================================= Servers =======================================
Please check the servers of the cluster. 1 continue; 2 clear server config (Default 1)
Please check the servers of the cluster. 1 continue; 2 clear server config (Default 1)
1
Please enter work node: ----添加一个work节点
Please enter a virtual IP address with network, such as (192.168.217.234/16):
192.168.121.202/24
The cluster need a primary server(required), one or more standby server(optional) and a witness server(optional).
Please input a primary server ip which is actually the ip of the current server(required). such as (192.168.217.234/16):
192.168.121.213/24 
Please input a standby server ip(required), such as (192.168.217.234/16):
192.168.121.214/24
Please enter status of the standby server [192.168.121.214]
1 sync:
2 async:
1
Continue to add standby nodes?(enter [exit] to left.):
exit
Please input a witness server ip(optional), such as (192.168.217.234/16):

Witness is empty
Please enter a port of the cluster. (Default port 5432):

======================================= Servers =======================================
Vip: 192.168.121.202
Port: 5432
Ip: 192.168.121.213 Role: primary Status: none
Ip: 192.168.121.214 Role: standby Status: sync
======================================= Servers =======================================
Please check the servers of the cluster. 1 continue; 2 clear server config (Default 1)
Please enter work node: ---添加第二个work
Please enter a virtual IP address with network, such as (192.168.217.234/16):
192.168.121.203/24
The cluster need a primary server(required), one or more standby server(optional) and a witness server(optional).
Please input a primary server ip which is actually the ip of the current server(required). such as (192.168.217.234/16):
192.168.121.215/24
Please input a standby server ip(required), such as (192.168.217.234/16):
192.168.121.216/24
Please enter status of the standby server [192.168.121.216]
1 sync:
2 async:
1
Continue to add standby nodes?(enter [exit] to left.):
exit
Please input a witness server ip(optional), such as (192.168.217.234/16):

Witness is empty
Please enter a port of the cluster. (Default port 5432):

======================================= Servers =======================================
Vip: 192.168.121.203
Port: 5432
Ip: 192.168.121.215 Role: primary Status: none
Ip: 192.168.121.216 Role: standby Status: sync
======================================= Servers =======================================
Please check the servers of the cluster. 1 continue; 2 clear server config (Default 1)
1
Continue to add worker node(1[yes],2[no])?
2
====================================== Generate pg_hba ================================
====================================== Generate end ===================================
====================================== Copying files takes time =======================
192.168.121.212: start copy
192.168.121.212: end copy
192.168.121.213: start copy
192.168.121.213: end copy
192.168.121.214: start copy
192.168.121.214: end copy
192.168.121.215: start copy
192.168.121.215: end copy
192.168.121.216: start copy
192.168.121.216: end copy
====================================== Copying files end ==============================
Check system parameters and dependency packages!
========================================= 192.168.121.211 =========================================
NETWORK
name: sem, recommend value: 500,2048000,200,4096, current value: 500,2048000,200,4096, status: OK
name: aio_max_nr, recommend value: 1048576, current value: 1048576, status: OK
name: somaxconn, recommend value: 2000, current value: 2000, status: OK
name: tcp_max_syn_backlog, recommend value: 2000, current value: 2000, status: OK
name: tcp_tw_reuse, recommend value: 1, current value: 1, status: OK
name: tcp_syn_retries, recommend value: 3, current value: 3, status: OK
name: tcp_retries2, recommend value: 5, current value: 5, status: OK
name: tcp_slow_start_after_idle, recommend value: 0, current value: 0, status: OK
PAGE_CACHE
name: dirty_background_ratio, recommend value: 5, current value: 5, status: OK
name: dirty_ratio, recommend value: 40, current value: 40, status: OK
name: dirty_expire_centisecs, recommend value: 500, current value: 500, status: OK
name: dirty_writeback_centisecs, recommend value: 250, current value: 250, status: OK
MEMORY
name: shmmni, recommend value: 4096, current value: 4096, status: OK
name: shmmax, recommend value: 953868288, current value: 1976979456, status: WARNING
name: shmall, recommend value: 232878, current value: 482661, status: WARNING
name: swappiness, recommend value: 5, current value: 5, status: OK
name: overcommit_memory, recommend value: 2, current value: 2, status: OK
name: overcommit_ratio, recommend value: 75, current value: 75, status: OK
FILE_HANDLER
name: file_max, recommend value: 524288, current value: 524288, status: OK
ULIMIT
name: ulimit_core, recommend value: unlimited, current value: unlimited, status: OK
name: ulimit_nofile, recommend value: 8192, current value: 524288, status: OK
Dependency Package
name: JSON-C-0.11 is existed: yes
name: C-ARES-1 is existed: yes
name: LIBNL3 is existed: yes
name: LIBPCAP-1 is existed: yes
name: LIBZSTD-1 is existed: yes
name: LZ4-1 is existed: yes
name: NCURSES-LIBS-5 is existed: yes
name: READLINE-6 is existed: yes
name: SNAPPY-1 is existed: yes
name: UUID-1.6 is existed: yes
name: LIBICU-50 is existed: yes
System service
name: ntp is install: no
========================================= 192.168.121.212 =========================================
.....
========================================= 192.168.121.213 =========================================
.....
========================================= 192.168.121.214 =========================================
.....
========================================= 192.168.121.215 =========================================
.....
========================================= 192.168.121.216 =========================================
NETWORK
name: sem, recommend value: 500,2048000,200,4096, current value: 500,2048000,200,4096, status: OK
name: aio_max_nr, recommend value: 1048576, current value: 1048576, status: OK
name: somaxconn, recommend value: 2000, current value: 2000, status: OK
name: tcp_max_syn_backlog, recommend value: 2000, current value: 2000, status: OK
name: tcp_tw_reuse, recommend value: 1, current value: 1, status: OK
name: tcp_syn_retries, recommend value: 3, current value: 3, status: OK
name: tcp_retries2, recommend value: 5, current value: 5, status: OK
name: tcp_slow_start_after_idle, recommend value: 0, current value: 0, status: OK
PAGE_CACHE
name: dirty_background_ratio, recommend value: 5, current value: 5, status: OK
name: dirty_ratio, recommend value: 40, current value: 40, status: OK
name: dirty_expire_centisecs, recommend value: 500, current value: 500, status: OK
name: dirty_writeback_centisecs, recommend value: 250, current value: 250, status: OK
MEMORY
name: shmmni, recommend value: 4096, current value: 4096, status: OK
name: shmmax, recommend value: 1976979456, current value: 1976979456, status: OK
name: shmall, recommend value: 482661, current value: 482661, status: OK
name: swappiness, recommend value: 5, current value: 5, status: OK
name: overcommit_memory, recommend value: 2, current value: 2, status: OK
name: overcommit_ratio, recommend value: 75, current value: 75, status: OK
FILE_HANDLER
name: file_max, recommend value: 524288, current value: 524288, status: OK
ULIMIT
name: ulimit_core, recommend value: unlimited, current value: unlimited, status: OK
name: ulimit_nofile, recommend value: 8192, current value: 524288, status: OK
Dependency Package
name: JSON-C-0.11 is existed: yes
name: C-ARES-1 is existed: yes
name: LIBNL3 is existed: yes
name: LIBPCAP-1 is existed: yes
name: LIBZSTD-1 is existed: yes
name: LZ4-1 is existed: yes
name: NCURSES-LIBS-5 is existed: yes
name: READLINE-6 is existed: yes
name: SNAPPY-1 is existed: yes
name: UUID-1.6 is existed: yes
name: LIBICU-50 is existed: yes
System service
name: ntp is install: no
Choice a kind of Compatible Type!
1: LightdDB(Compatible with PostgreSQL).
2: ORACLE(Compatible with ORACLE).
3: MYSQL(Compatible with MYSQL).
Please enter 1, 2 or 3:(The default is 1)
1
Choice a kind of LightDB workload!
1: OLTP(On-line Transaction Processing).
2: OLAP(On-Line Analytical Processing).
Please enter 1 or 2:(The default is 1)
1
Specify a path for installing all LightDB software and storing configuration information.
Please enter base location(The default is /usr/local/lightdb):

Base Location: /usr/local/lightdb
Install Location: /usr/local/lightdb/lightdb-x/13.8-22.3
Please enter instance location(The default is /usr/local/lightdb/lightdb-x/13.8-22.3/data/defaultCluster/):

Instance location: /usr/local/lightdb/lightdb-x/13.8-22.3/data/defaultCluster/
Please configure memory(MB) and character set!
Please enter shared_buffers, Default value is (454):

Please enter effective_cache_size, Default value is (1273):

Please choice a kind of Character Set.
1. UTF8
2. GBK
3. SQL_ASCII
4. LATIN1
The default choice 1(UTF8)
1
Please enter LightDB password!
Please enter original password:
Please enter confirm password:

Do you want to deploy immediately?(Yes or No, The default is yes)
yes

  • 问题
#ssh超时
packet_write_wait: Connection to 192.168.121.214 port 22: Broken pipe
解决;~/.ssh/config文件中添加
$ vi ~/.ssh/config
ServerAliveInterval 60
IPQoS lowdelay throughput

到了这里,关于2023-01-13 LightDB分布式部署.md的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处: 如若内容造成侵权/违法违规/事实不符,请点击违法举报进行投诉反馈,一经查实,立即删除!

领支付宝红包 赞助服务器费用

相关文章

  • DAY-01--分布式&微服务基础概念

    了解整体项目包含后端、前端、周边维护。整个项目的框架知识。   1、微服务         将应用程序 基于业务 拆分为 多个小服务,各小服务单独部署运行,采用http通信。 2、集群分布式节点         集群是个物理形态,分布式是工作方式。         集群:将几台

    2024年02月09日
    浏览(44)
  • 聊聊分布式架构01——http通信基础

    目录 web通信的简单结构 网络通信基础TCP/IP TCP/IP 通信传输流 HTTP中的三剑客 负责传输的IP协议 确保可靠性的TCP协议 SYN攻击(SYN Flood Attack) 四次挥手 负责域名解析的DNS服务 基于 TCP 协议实现通信 TCP 协议的通信过程 Web通信的简单结构 Web 使用一种名为 HTTP(HyperText Transfer Pr

    2024年02月07日
    浏览(42)
  • L3上云01 | 分布式、微服务概念

    分布式系统一定是由多个节点组成的系统。 其中,节点指的是计算机服务器,而且这些节点一般不是孤立的,而是互通的。 这些连通的节点上部署了我们的节点,并且相互的操作会有协同。 分布式系统对于用户而言,他们面对的就是一个服务器,提供用户需要的服务而已,

    2024年01月18日
    浏览(44)
  • 微服务架构学习与思考(13):分布式配置中心

    微服务架构系列文章集合:https://www.cnblogs.com/jiujuan/p/17307285.html 用编程语言编写应用项目时,一般都会有项目的配置文件。比如用 java 编写项目,有一个 properties 的配置文件,会把一些配置信息写入到该文本文件中,例如数据库相关的配置信息。 这也体现了软件设计的一个原

    2024年02月06日
    浏览(50)
  • SpringCloud学习路线(13)——分布式搜索ElasticSeach集群

    前言 单机ES做数据存储,必然面临两个问题: 海量数据的存储 , 单点故障 。 如何解决这两个问题? 海量数据的存储问题: 将索引库从逻辑上拆分为N个分片(shard),存储到多个节点。 单点故障问题: 将分片数据在不同节点备份(replica) 缺点是什么? 造成资源的消耗的

    2024年02月15日
    浏览(36)
  • 微服务13-Seata的四种分布式事务模式

    XA模式分为两种情况 : 提交成功: 提交失败: 具有强一致性seata相当于是在RM上做了一层封装; XA模式 优点 : 1.事务的强一致性,只要有失败的,TC事务协调者就会发送信息让RM回滚——满足ACID原则 2.没有代码侵入,常用数据库都支持 缺点 : 1.第一阶段就要锁定数据库资源

    2024年02月07日
    浏览(43)
  • Spring Cloud学习(九)【Elasticsearch 分布式搜索引擎01】

    Elasticsearch 是一款非常强大的开源搜索引擎,可以帮助我们从海量数据中快速找到需要的内容。 elasticsearch 结合 kibana、Logstash、Beats,也就是 elastic stack(ELK) 。被广泛应用在日志数据分析、实时监控等领域。 elasticsearch 是 elastic stack 的核心,负责 存储、搜索、分析数据 。

    2024年02月05日
    浏览(41)
  • Hadoop(01) Hadoop3.3.6安装教程,单机/伪分布式配置

    在安装 Hadoop 3.3.6 前,需要满足以下前置条件: Java Development Kit (JDK):Hadoop 是用 Java 编写的,因此需要安装并配置适当版本的 JDK。Hadoop 3.3.6 建议使用 JDK 8 或更高版本。确保正确安装 JDK,并设置 JAVA_HOME 环境变量。 SSH:Hadoop 集群中的节点需要通过 SSH 进行通信和管理。确保在

    2024年02月06日
    浏览(48)
  • 分布式内存计算Spark环境部署与分布式内存计算Flink环境部署

    目录 分布式内存计算Spark环境部署 1.  简介 2.  安装 2.1【node1执行】下载并解压 2.2【node1执行】修改配置文件名称 2.3【node1执行】修改配置文件,spark-env.sh 2.4 【node1执行】修改配置文件,slaves 2.5【node1执行】分发 2.6【node2、node3执行】设置软链接 2.7【node1执行】启动Spark集群

    2024年02月08日
    浏览(76)
  • 【分布式技术】分布式存储ceph之RBD块存储部署

    目录 创建 Ceph 块存储系统 RBD 接口 服务端操作 1、创建一个名为 rbd-demo 的专门用于 RBD 的存储池 2、将存储池转换为 RBD 模式 3、初始化存储池 4、创建镜像 5、在管理节点创建并授权一个用户可访问指定的 RBD 存储池 6、修改RBD镜像特性,CentOS7默认情况下只支持layering和stripin

    2024年01月18日
    浏览(75)

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

博客赞助

微信扫一扫打赏

请作者喝杯咖啡吧~博客赞助

支付宝扫一扫领取红包,优惠每天领

二维码1

领取红包

二维码2

领红包